]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
tool_libinfo: silence "different 'const' qualifiers" in qsort()
authorDaniel Stenberg <daniel@haxx.se>
Sat, 17 Sep 2022 09:38:59 +0000 (11:38 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Sat, 17 Sep 2022 11:54:56 +0000 (13:54 +0200)
MSVC 15.0.30729.1 warned about it

Follow-up to dd2a024323dcc

Closes #9522

src/tool_libinfo.c

index 5f7bd608f57b105d42c233d4fa47e5507f74787a..1fc2996be481e35e1900f5662b805f9b46f826a9 100644 (file)
@@ -187,9 +187,10 @@ CURLcode get_libcurl_info(void)
     if(result)
       return result;
 
-    /* Sort the protocols to be sure the primary ones are always accessible and
-     * to retain their list order for testing purposes. */
-    qsort(built_in_protos, proto_last, sizeof(built_in_protos[0]), protocmp);
+    /* Sort the protocols to be sure the primary ones are always accessible
+     * and to retain their list order for testing purposes. */
+    qsort((char *)built_in_protos, proto_last,
+          sizeof(built_in_protos[0]), protocmp);
 
     /* Identify protocols we are interested in. */
     for(p = possibly_built_in; p->proto_name; p++)