Skip to content

Commit

Permalink
Fix build error with -DTRITON_ENABLE_METRICS=OFF
Browse files Browse the repository at this point in the history
  • Loading branch information
yinggeh committed Aug 16, 2024
1 parent 349daa6 commit c3d478a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/tritonserver.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3386,7 +3386,7 @@ TRITONSERVER_MetricArgsNew(TRITONSERVER_MetricArgs** args)
*args = reinterpret_cast<TRITONSERVER_MetricArgs*>(largs);
return nullptr; // Success
#else
*metrics = nullptr;
*args = nullptr;
return TRITONSERVER_ErrorNew(
TRITONSERVER_ERROR_UNSUPPORTED, "metrics not supported");
#endif // TRITON_ENABLE_METRICS
Expand All @@ -3402,7 +3402,6 @@ TRITONSERVER_MetricArgsSetHistogram(
largs->SetHistogramArgs(buckets, buckets_count);
return nullptr; // Success
#else
*metrics = nullptr;
return TRITONSERVER_ErrorNew(
TRITONSERVER_ERROR_UNSUPPORTED, "metrics not supported");
#endif // TRITON_ENABLE_METRICS
Expand Down

0 comments on commit c3d478a

Please sign in to comment.