]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
CURLOPT: bump `CURLALTSVC_*` macros to `long`
authorViktor Szakats <commit@vsz.me>
Mon, 28 Jul 2025 12:56:18 +0000 (14:56 +0200)
committerViktor Szakats <commit@vsz.me>
Mon, 28 Jul 2025 15:30:36 +0000 (17:30 +0200)
This patch bumps the size of these macros from `int` to `long`, while
keeping their actual values the same. It may cause incompatibilities in
user code, requiring the bump of holder variables and/or adding casts:

- CURLALTSVC_H1
- CURLALTSVC_H2
- CURLALTSVC_H3
- CURLALTSVC_READONLYFILE

Also:
- keep existing cast within the documentation to make sure it applies
  to older curl versions as well.

Closes #18063

include/curl/curl.h

index 258cc28becff1eb46c9100a7163f2b39d186725e..f03459093bec45219b481762037b5825ffb58056 100644 (file)
@@ -1024,10 +1024,10 @@ typedef enum {
 #define CURLHEADER_SEPARATE (1<<0)
 
 /* CURLALTSVC_* are bits for the CURLOPT_ALTSVC_CTRL option */
-#define CURLALTSVC_READONLYFILE (1<<2)
-#define CURLALTSVC_H1           (1<<3)
-#define CURLALTSVC_H2           (1<<4)
-#define CURLALTSVC_H3           (1<<5)
+#define CURLALTSVC_READONLYFILE (1L<<2)
+#define CURLALTSVC_H1           (1L<<3)
+#define CURLALTSVC_H2           (1L<<4)
+#define CURLALTSVC_H3           (1L<<5)
 
 /* bitmask values for CURLOPT_UPLOAD_FLAGS */
 #define CURLULFLAG_ANSWERED (1L<<0)