summaryrefslogtreecommitdiff
path: root/docs/examples
diff options
context:
space:
mode:
authorMattias Fornander <mfornander@nvidia.com>2017-12-20 11:48:26 -0700
committerJay Satiro <raysatiro@yahoo.com>2017-12-22 02:59:08 -0500
commitb437557896abf2d164e5cf9606dc4e9c4fa6cd92 (patch)
treef1892abc90a0f6c44d1ad439bc22c796efe8228e /docs/examples
parentf009bbe1f625b19236dc2ed57726b2f0f39a27c4 (diff)
downloadcurl-b437557896abf2d164e5cf9606dc4e9c4fa6cd92.tar.gz
examples/rtsp: fix error handling macros
Closes https://github.com/curl/curl/pull/2185
Diffstat (limited to 'docs/examples')
-rw-r--r--docs/examples/rtsp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/examples/rtsp.c b/docs/examples/rtsp.c
index 3035e3fbc..32084e9ef 100644
--- a/docs/examples/rtsp.c
+++ b/docs/examples/rtsp.c
@@ -63,13 +63,13 @@ static int _getch(void)
/* error handling macros */
#define my_curl_easy_setopt(A, B, C) \
res = curl_easy_setopt((A), (B), (C)); \
- if(!res) \
+ if(res != CURLE_OK) \
fprintf(stderr, "curl_easy_setopt(%s, %s, %s) failed: %d\n", \
#A, #B, #C, res);
#define my_curl_easy_perform(A) \
res = curl_easy_perform(A); \
- if(!res) \
+ if(res != CURLE_OK) \
fprintf(stderr, "curl_easy_perform(%s) failed: %d\n", #A, res);