Mercurial > vim
diff src/proto.h @ 15896:ac080f6a4db8 v8.1.0954
patch 8.1.0954: arguments of semsg() and siemsg() are not checked
commit https://github.com/vim/vim/commit/0d8562a9992e94d532485c37268ca33c0c49ecc2
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Feb 19 21:34:05 2019 +0100
patch 8.1.0954: arguments of semsg() and siemsg() are not checked
Problem: Arguments of semsg() and siemsg() are not checked.
Solution: Add function prototype with __attribute__.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 19 Feb 2019 21:45:07 +0100 |
parents | 7fad90423bd2 |
children | 570a296aa0b4 |
line wrap: on
line diff
--- a/src/proto.h +++ b/src/proto.h @@ -134,6 +134,28 @@ smsg_attr_keep(int, const char *, ...) #endif ; +/* These prototypes cannot be produced automatically. */ +int +# ifdef __BORLANDC__ +_RTLENTRYF +# endif +semsg(const char *, ...) +#ifdef USE_PRINTF_FORMAT_ATTRIBUTE + __attribute__((format(printf, 1, 0))) +#endif + ; + +/* These prototypes cannot be produced automatically. */ +void +# ifdef __BORLANDC__ +_RTLENTRYF +# endif +siemsg(const char *, ...) +#ifdef USE_PRINTF_FORMAT_ATTRIBUTE + __attribute__((format(printf, 1, 0))) +#endif + ; + int # ifdef __BORLANDC__ _RTLENTRYF