@@ -90,9 +90,9 @@ static int otel_exporter_set_otlp_file_options(const char *desc, const char *pat
9090 OTELC_FUNC (" \" %s\" , \" %s\" , <options>, %p:%p, \" %s\" " , OTELC_STR_ARG (desc), OTELC_STR_ARG (path), OTELC_DPTR_ARGS (err), OTELC_STR_ARG (name));
9191
9292 if (OTEL_NULL (desc))
93- OTEL_ERETURN_INT (" Exporter description not specified" );
93+ OTEL_ERR_RETURN_INT (" Exporter description not specified" );
9494 else if (OTEL_NULL (path))
95- OTEL_ERETURN_INT (" Exporter path not specified" );
95+ OTEL_ERR_RETURN_INT (" Exporter path not specified" );
9696
9797 rc = yaml_get_node (otelc_fyd, err, 1 , desc, path, name,
9898 OTEL_YAML_ARG_STR (0 , EXPORTERS, thread_name),
@@ -107,9 +107,9 @@ static int otel_exporter_set_otlp_file_options(const char *desc, const char *pat
107107 OTELC_RETURN_INT (OTELC_RET_ERROR);
108108 else if (rc == 0 ) {
109109 if (OTEL_NULL (name))
110- OTEL_ERETURN_INT (" OpenTelemetry exporter type not specified" );
110+ OTEL_ERR_RETURN_INT (" OpenTelemetry exporter type not specified" );
111111 else
112- OTEL_ERETURN_INT (" '%s': OpenTelemetry exporter type not specified" , name);
112+ OTEL_ERR_RETURN_INT (" '%s': OpenTelemetry exporter type not specified" , name);
113113 }
114114
115115 fs_options.file_pattern = file_pattern;
@@ -178,11 +178,11 @@ static int otel_exporter_set_otlp_grpc_options(const char *desc, const char *pat
178178 OTELC_FUNC (" \" %s\" , \" %s\" , \" %s\" , <options>, %p:%p, \" %s\" " , OTELC_STR_ARG (desc), OTELC_STR_ARG (path), OTELC_STR_ARG (endpoint), OTELC_DPTR_ARGS (err), OTELC_STR_ARG (name));
179179
180180 if (OTEL_NULL (desc))
181- OTEL_ERETURN_INT (" Exporter description not specified" );
181+ OTEL_ERR_RETURN_INT (" Exporter description not specified" );
182182 else if (OTEL_NULL (path))
183- OTEL_ERETURN_INT (" Exporter path not specified" );
183+ OTEL_ERR_RETURN_INT (" Exporter path not specified" );
184184 else if (OTEL_NULL (endpoint))
185- OTEL_ERETURN_INT (" Exporter endpoint not specified" );
185+ OTEL_ERR_RETURN_INT (" Exporter endpoint not specified" );
186186
187187 rc = yaml_get_node (otelc_fyd, err, 1 , desc, path, name,
188188 OTEL_YAML_ARG_STR (0 , EXPORTERS, thread_name),
@@ -279,11 +279,11 @@ static int otel_exporter_set_otlp_http_options(const char *desc, const char *pat
279279 OTELC_FUNC (" \" %s\" , \" %s\" , \" %s\" , <options>, %p:%p, \" %s\" " , OTELC_STR_ARG (desc), OTELC_STR_ARG (path), OTELC_STR_ARG (endpoint), OTELC_DPTR_ARGS (err), OTELC_STR_ARG (name));
280280
281281 if (OTEL_NULL (desc))
282- OTEL_ERETURN_INT (" Exporter description not specified" );
282+ OTEL_ERR_RETURN_INT (" Exporter description not specified" );
283283 else if (OTEL_NULL (path))
284- OTEL_ERETURN_INT (" Exporter path not specified" );
284+ OTEL_ERR_RETURN_INT (" Exporter path not specified" );
285285 else if (OTEL_NULL (endpoint))
286- OTEL_ERETURN_INT (" Exporter endpoint not specified" );
286+ OTEL_ERR_RETURN_INT (" Exporter endpoint not specified" );
287287
288288 rc = yaml_get_node (otelc_fyd, err, 1 , desc, path, name,
289289 OTEL_YAML_ARG_STR (0 , EXPORTERS, thread_name),
@@ -319,7 +319,7 @@ static int otel_exporter_set_otlp_http_options(const char *desc, const char *pat
319319 else if (strcasecmp (content_type, " binary" ) == 0 )
320320 options.content_type = otel_exporter_otlp::HttpRequestContentType::kBinary ;
321321 else if (*content_type != ' \0 ' )
322- OTEL_ERETURN_INT (" Invalid content_type: '%s'" , content_type);
322+ OTEL_ERR_RETURN_INT (" Invalid content_type: '%s'" , content_type);
323323
324324 /* <opentelemetry/exporters/otlp/otlp_http.h> */
325325 if (strcasecmp (json_bytes_mapping, " hexid" ) == 0 )
@@ -329,15 +329,15 @@ static int otel_exporter_set_otlp_http_options(const char *desc, const char *pat
329329 else if (strcasecmp (json_bytes_mapping, " base64" ) == 0 )
330330 options.json_bytes_mapping = otel_exporter_otlp::JsonBytesMappingKind::kBase64 ;
331331 else if (*json_bytes_mapping != ' \0 ' )
332- OTEL_ERETURN_INT (" Invalid json_bytes_mapping: '%s'" , json_bytes_mapping);
332+ OTEL_ERR_RETURN_INT (" Invalid json_bytes_mapping: '%s'" , json_bytes_mapping);
333333
334334 if (!OTEL_NULL (http_headers))
335335 for (size_t i = 0 ; i < http_headers->count ; i++) {
336336 try {
337337 OTEL_DBG_THROW ();
338338 otlp_http_headers.emplace (std::string{http_headers->key [i]}, std::string{http_headers->value [i]});
339339 }
340- OTEL_CATCH_ERETURN ( , OTEL_ERETURN_INT , " Unable to add HTTP header" )
340+ OTEL_CATCH_SIGNAL_RETURN ( , OTEL_ERR_RETURN_INT , " Unable to add HTTP header" )
341341 }
342342
343343 options.url = endpoint;
@@ -409,9 +409,9 @@ static int otel_exporter_set_ostream_options(const char *desc, const char *path,
409409 OTELC_FUNC (" \" %s\" , \" %s\" , <stream>, <exporter>, %p:%p, \" %s\" " , OTELC_STR_ARG (desc), OTELC_STR_ARG (path), OTELC_DPTR_ARGS (err), OTELC_STR_ARG (name));
410410
411411 if (OTEL_NULL (desc))
412- OTEL_ERETURN_INT (" Exporter description not specified" );
412+ OTEL_ERR_RETURN_INT (" Exporter description not specified" );
413413 else if (OTEL_NULL (path))
414- OTEL_ERETURN_INT (" Exporter path not specified" );
414+ OTEL_ERR_RETURN_INT (" Exporter path not specified" );
415415
416416 rc = yaml_get_node (otelc_fyd, err, 1 , desc, path, name, OTEL_YAML_ARG_STR (0 , EXPORTERS, filename), OTEL_YAML_END);
417417 if (rc == OTELC_RET_ERROR)
@@ -426,7 +426,7 @@ static int otel_exporter_set_ostream_options(const char *desc, const char *path,
426426 else {
427427 stream.open (filename, std::ios::out);
428428 if (stream.fail ())
429- OTEL_ERETURN_INT (" '%s': %s" , filename, otel_strerror (errno));
429+ OTEL_ERR_RETURN_INT (" '%s': %s" , filename, otel_strerror (errno));
430430 else
431431 exporter = otel::make_unique_nothrow<C>(stream);
432432 }
@@ -435,7 +435,7 @@ static int otel_exporter_set_ostream_options(const char *desc, const char *path,
435435 if (stream.is_open ())
436436 stream.close ();
437437
438- OTEL_ERETURN_INT (" Unable to create ostream exporter" );
438+ OTEL_ERR_RETURN_INT (" Unable to create ostream exporter" );
439439 }
440440
441441 OTELC_RETURN_INT (OTELC_RET_OK);
@@ -525,7 +525,7 @@ int otel_tracer_exporter_create(struct otelc_tracer *tracer, std::unique_ptr<ote
525525 else if (strcasecmp (format, " protobuf" ) == 0 )
526526 options.format = otel_exporter_zipkin::TransportFormat::kProtobuf ;
527527 else if (*format != ' \0 ' )
528- OTEL_TRACER_ERETURN_INT (" Invalid Zipkin exporter format: '%s'" , format);
528+ OTEL_TRACER_RETURN_INT (" Invalid Zipkin exporter format: '%s'" , format);
529529
530530 options.endpoint = endpoint;
531531 options.service_name = service_name;
@@ -757,7 +757,7 @@ int otel_logger_exporter_create(struct otelc_logger *logger, std::unique_ptr<ote
757757 OTEL_DBG_THROW ();
758758 es_http_headers.emplace (std::string{http_headers->key [i]}, std::string{http_headers->value [i]});
759759 }
760- OTEL_CATCH_ERETURN ( , OTEL_LOGGER_ERETURN_INT , " Unable to add HTTP header" )
760+ OTEL_CATCH_SIGNAL_RETURN ( , OTEL_LOGGER_RETURN_INT , " Unable to add HTTP header" )
761761 }
762762
763763 options.host_ = host;
0 commit comments