From ea07a64cf6630d27fd57fb51d145e19d87329cf5 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 21 Feb 2025 17:30:46 +0100 Subject: [PATCH] cmake: avoid `-Wnonnull` warning in `HAVE_FSETXATTR_5` detection Seen in Android 21/35 CI jobs: ``` curl/CMake/CurlTests.c:315:16: warning: null passed to a callee that requires a non-null argument [-Wnonnull] 315 | fsetxattr(0, 0, 0, 0, 0); | ^ 1 warning generated. ``` Ref: https://github.com/curl/curl/actions/runs/13460225795/job/37613494183#step:9:5978 Follow-up to bd9f9b085aa242a5e93be0b2da96ce498d7813c4 #16377 Closes #16427 --- CMake/CurlTests.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMake/CurlTests.c b/CMake/CurlTests.c index b11d0c6dd1b3..69a996a0477d 100644 --- a/CMake/CurlTests.c +++ b/CMake/CurlTests.c @@ -312,7 +312,7 @@ int main(void) #include /* header from libc, not from libattr */ int main(void) { - fsetxattr(0, 0, 0, 0, 0); + fsetxattr(0, "", 0, 0, 0); return 0; } #endif