Skip to content

Commit ed04fa2

Browse files
committed
Write timeouts to stderr.
1 parent ff024e2 commit ed04fa2

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

include/cmr/env.h

+6-6
Original file line numberDiff line numberDiff line change
@@ -45,16 +45,16 @@ typedef enum
4545
if (_cmr_error) \
4646
{ \
4747
if (_cmr_error == CMR_ERROR_INPUT) \
48-
printf("User input error"); \
48+
fprintf(stderr, "User input error"); \
4949
else if (_cmr_error == CMR_ERROR_MEMORY) \
50-
printf("Memory (re)allocation failed"); \
50+
fprintf(stderr, "Memory (re)allocation failed"); \
5151
else if (_cmr_error == CMR_ERROR_INVALID) \
52-
printf("Invalid input"); \
52+
fprintf(stderr, "Invalid input"); \
5353
else if (_cmr_error == CMR_ERROR_TIMEOUT) \
54-
printf("Time limit exceeded"); \
54+
fprintf(stderr, "Time limit exceeded"); \
5555
else \
56-
printf("Unknown error"); \
57-
printf(" in %s:%d.\n", __FILE__, __LINE__); \
56+
fprintf(stderr, "Unknown error"); \
57+
fprintf(stderr, " in %s:%d.\n", __FILE__, __LINE__); \
5858
return _cmr_error; \
5959
} \
6060
} while (false)

0 commit comments

Comments
 (0)