aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2024-01-02 09:38:11 +0000
committerRon Yorston <rmy@pobox.com>2024-01-17 11:57:42 +0000
commit99d22da0e95d8356239c63199eb03f70adbf7a61 (patch)
treed7ce8b095e41d5db964f686acd3c1481a1f9b5da /include
parentc0b57922a9373395c58139b2d4fe4cd865ef8223 (diff)
downloadbusybox-w32-99d22da0e95d8356239c63199eb03f70adbf7a61.tar.gz
busybox-w32-99d22da0e95d8356239c63199eb03f70adbf7a61.tar.bz2
busybox-w32-99d22da0e95d8356239c63199eb03f70adbf7a61.zip
Remove FAST_FUNC from variadic functions
The GCC documentation points out that the stdcall attribute doesn't apply to functions which take a variable number of arguments. GCC is silent about this during compilation but clang complains noisily. Remove FAST_FUNC from all variadic functions. This has no effect whatsoever on the binary resulting from a default 32-bit build. Signed-off-by: Ron Yorston <rmy@pobox.com>
Diffstat (limited to 'include')
-rw-r--r--include/libbb.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/include/libbb.h b/include/libbb.h
index 6549c8c83..96496169d 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -980,7 +980,7 @@ int bb_putchar(int ch) FAST_FUNC;
980/* Note: does not use stdio, writes to fd 2 directly */ 980/* Note: does not use stdio, writes to fd 2 directly */
981int bb_putchar_stderr(char ch) FAST_FUNC; 981int bb_putchar_stderr(char ch) FAST_FUNC;
982int fputs_stdout(const char *s) FAST_FUNC; 982int fputs_stdout(const char *s) FAST_FUNC;
983char *xasprintf(const char *format, ...) __attribute__ ((format(printf, 1, 2))) FAST_FUNC RETURNS_MALLOC; 983char *xasprintf(const char *format, ...) __attribute__ ((format(printf, 1, 2))) RETURNS_MALLOC;
984char *auto_string(char *str) FAST_FUNC; 984char *auto_string(char *str) FAST_FUNC;
985// gcc-4.1.1 still isn't good enough at optimizing it 985// gcc-4.1.1 still isn't good enough at optimizing it
986// (+200 bytes compared to macro) 986// (+200 bytes compared to macro)
@@ -1416,12 +1416,12 @@ char* single_argv(char **argv) FAST_FUNC;
1416char **skip_dash_dash(char **argv) FAST_FUNC; 1416char **skip_dash_dash(char **argv) FAST_FUNC;
1417extern const char *const bb_argv_dash[]; /* { "-", NULL } */ 1417extern const char *const bb_argv_dash[]; /* { "-", NULL } */
1418extern uint32_t option_mask32; 1418extern uint32_t option_mask32;
1419uint32_t getopt32(char **argv, const char *applet_opts, ...) FAST_FUNC; 1419uint32_t getopt32(char **argv, const char *applet_opts, ...);
1420# define No_argument "\0" 1420# define No_argument "\0"
1421# define Required_argument "\001" 1421# define Required_argument "\001"
1422# define Optional_argument "\002" 1422# define Optional_argument "\002"
1423#if ENABLE_LONG_OPTS 1423#if ENABLE_LONG_OPTS
1424uint32_t getopt32long(char **argv, const char *optstring, const char *longopts, ...) FAST_FUNC; 1424uint32_t getopt32long(char **argv, const char *optstring, const char *longopts, ...);
1425#else 1425#else
1426#define getopt32long(argv,optstring,longopts,...) \ 1426#define getopt32long(argv,optstring,longopts,...) \
1427 getopt32(argv,optstring,##__VA_ARGS__) 1427 getopt32(argv,optstring,##__VA_ARGS__)
@@ -1496,17 +1496,17 @@ extern uint8_t xfunc_error_retval;
1496extern void (*die_func)(void); 1496extern void (*die_func)(void);
1497void xfunc_die(void) NORETURN FAST_FUNC; 1497void xfunc_die(void) NORETURN FAST_FUNC;
1498void bb_show_usage(void) NORETURN FAST_FUNC; 1498void bb_show_usage(void) NORETURN FAST_FUNC;
1499void bb_error_msg(const char *s, ...) __attribute__ ((format (printf, 1, 2))) FAST_FUNC; 1499void bb_error_msg(const char *s, ...) __attribute__ ((format (printf, 1, 2)));
1500void bb_simple_error_msg(const char *s) FAST_FUNC; 1500void bb_simple_error_msg(const char *s) FAST_FUNC;
1501void bb_error_msg_and_die(const char *s, ...) __attribute__ ((noreturn, format (printf, 1, 2))) FAST_FUNC; 1501void bb_error_msg_and_die(const char *s, ...) __attribute__ ((noreturn, format (printf, 1, 2)));
1502void bb_simple_error_msg_and_die(const char *s) NORETURN FAST_FUNC; 1502void bb_simple_error_msg_and_die(const char *s) NORETURN FAST_FUNC;
1503void bb_perror_msg(const char *s, ...) __attribute__ ((format (printf, 1, 2))) FAST_FUNC; 1503void bb_perror_msg(const char *s, ...) __attribute__ ((format (printf, 1, 2)));
1504void bb_simple_perror_msg(const char *s) FAST_FUNC; 1504void bb_simple_perror_msg(const char *s) FAST_FUNC;
1505void bb_perror_msg_and_die(const char *s, ...) __attribute__ ((noreturn, format (printf, 1, 2))) FAST_FUNC; 1505void bb_perror_msg_and_die(const char *s, ...) __attribute__ ((noreturn, format (printf, 1, 2)));
1506void bb_simple_perror_msg_and_die(const char *s) NORETURN FAST_FUNC; 1506void bb_simple_perror_msg_and_die(const char *s) NORETURN FAST_FUNC;
1507void bb_herror_msg(const char *s, ...) __attribute__ ((format (printf, 1, 2))) FAST_FUNC; 1507void bb_herror_msg(const char *s, ...) __attribute__ ((format (printf, 1, 2)));
1508void bb_simple_herror_msg(const char *s) FAST_FUNC; 1508void bb_simple_herror_msg(const char *s) FAST_FUNC;
1509void bb_herror_msg_and_die(const char *s, ...) __attribute__ ((noreturn, format (printf, 1, 2))) FAST_FUNC; 1509void bb_herror_msg_and_die(const char *s, ...) __attribute__ ((noreturn, format (printf, 1, 2)));
1510void bb_simple_herror_msg_and_die(const char *s) NORETURN FAST_FUNC; 1510void bb_simple_herror_msg_and_die(const char *s) NORETURN FAST_FUNC;
1511void bb_perror_nomsg_and_die(void) NORETURN FAST_FUNC; 1511void bb_perror_nomsg_and_die(void) NORETURN FAST_FUNC;
1512void bb_perror_nomsg(void) FAST_FUNC; 1512void bb_perror_nomsg(void) FAST_FUNC;
@@ -1522,7 +1522,7 @@ void bb_logenv_override(void) FAST_FUNC;
1522typedef smalluint exitcode_t; 1522typedef smalluint exitcode_t;
1523 1523
1524#if ENABLE_FEATURE_SYSLOG_INFO 1524#if ENABLE_FEATURE_SYSLOG_INFO
1525void bb_info_msg(const char *s, ...) __attribute__ ((format (printf, 1, 2))) FAST_FUNC; 1525void bb_info_msg(const char *s, ...) __attribute__ ((format (printf, 1, 2)));
1526void bb_simple_info_msg(const char *s) FAST_FUNC; 1526void bb_simple_info_msg(const char *s) FAST_FUNC;
1527void bb_vinfo_msg(const char *s, va_list p) FAST_FUNC; 1527void bb_vinfo_msg(const char *s, va_list p) FAST_FUNC;
1528#else 1528#else
@@ -1898,8 +1898,8 @@ int get_termios_and_make_raw(int fd, struct termios *newterm, struct termios *ol
1898int set_termios_to_raw(int fd, struct termios *oldterm, int flags) FAST_FUNC; 1898int set_termios_to_raw(int fd, struct termios *oldterm, int flags) FAST_FUNC;
1899 1899
1900/* NB: "unsigned request" is crucial! "int request" will break some arches! */ 1900/* NB: "unsigned request" is crucial! "int request" will break some arches! */
1901int ioctl_or_perror(int fd, unsigned request, void *argp, const char *fmt,...) __attribute__ ((format (printf, 4, 5))) FAST_FUNC; 1901int ioctl_or_perror(int fd, unsigned request, void *argp, const char *fmt,...) __attribute__ ((format (printf, 4, 5)));
1902int ioctl_or_perror_and_die(int fd, unsigned request, void *argp, const char *fmt,...) __attribute__ ((format (printf, 4, 5))) FAST_FUNC; 1902int ioctl_or_perror_and_die(int fd, unsigned request, void *argp, const char *fmt,...) __attribute__ ((format (printf, 4, 5)));
1903#if ENABLE_IOCTL_HEX2STR_ERROR 1903#if ENABLE_IOCTL_HEX2STR_ERROR
1904int bb_ioctl_or_warn(int fd, unsigned request, void *argp, const char *ioctl_name) FAST_FUNC; 1904int bb_ioctl_or_warn(int fd, unsigned request, void *argp, const char *ioctl_name) FAST_FUNC;
1905int bb_xioctl(int fd, unsigned request, void *argp, const char *ioctl_name) FAST_FUNC; 1905int bb_xioctl(int fd, unsigned request, void *argp, const char *ioctl_name) FAST_FUNC;