From bfb83bd61b806a6d10c5ae3c4f1c1b88cc6b9dd1 Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Wed, 4 Jun 2025 13:28:56 -0400 Subject: [PATCH] MT#55283 silence curl compiler warnings Change-Id: Ie0e4e292f10cf69e871a150957c957095bc3545b (cherry picked from commit 991a2c3bce32282f1439ae407c2d243ae382ef86) (cherry picked from commit a6923f2b733bf68dac2d5df0f776f55299c57922) --- daemon/call.c | 2 +- recording-daemon/notify.c | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/daemon/call.c b/daemon/call.c index 6d064b5c2..de9c32bb6 100644 --- a/daemon/call.c +++ b/daemon/call.c @@ -387,7 +387,7 @@ retry: goto fault; if ((ret = curl_easy_setopt(curl, CURLOPT_URL, url)) != CURLE_OK) goto fault; - if ((ret = curl_easy_setopt(curl, CURLOPT_POST, 1)) != CURLE_OK) + if ((ret = curl_easy_setopt(curl, CURLOPT_POST, 1L)) != CURLE_OK) goto fault; if ((ret = curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, cb_curl_write)) != CURLE_OK) goto fault; diff --git a/recording-daemon/notify.c b/recording-daemon/notify.c index 3c1e8cad9..d52ac29c0 100644 --- a/recording-daemon/notify.c +++ b/recording-daemon/notify.c @@ -64,12 +64,12 @@ static void do_notify(void *p, void *u) { /* allow redirects */ err = "setting CURLOPT_FOLLOWLOCATION"; - if ((ret = curl_easy_setopt(c, CURLOPT_FOLLOWLOCATION, 1)) != CURLE_OK) + if ((ret = curl_easy_setopt(c, CURLOPT_FOLLOWLOCATION, 1L)) != CURLE_OK) goto fail; /* max 5 redirects */ err = "setting CURLOPT_MAXREDIRS"; - if ((ret = curl_easy_setopt(c, CURLOPT_MAXREDIRS, 5)) != CURLE_OK) + if ((ret = curl_easy_setopt(c, CURLOPT_MAXREDIRS, 5L)) != CURLE_OK) goto fail; /* add headers */ @@ -80,14 +80,14 @@ static void do_notify(void *p, void *u) { /* POST vs GET */ if (notify_post) { err = "setting CURLOPT_POST"; - if ((ret = curl_easy_setopt(c, CURLOPT_POST, 1)) != CURLE_OK) + if ((ret = curl_easy_setopt(c, CURLOPT_POST, 1L)) != CURLE_OK) goto fail; } /* cert verify (enabled by default) */ if (notify_nverify) { err = "setting CURLOPT_SSL_VERIFYPEER"; - if ((ret = curl_easy_setopt(c, CURLOPT_SSL_VERIFYPEER, 0)) != CURLE_OK) + if ((ret = curl_easy_setopt(c, CURLOPT_SSL_VERIFYPEER, 0L)) != CURLE_OK) goto fail; }