Module: wine Branch: master Commit: fddd7aab7c49d7b833bd07090a03a870dc088cf1 URL: https://gitlab.winehq.org/wine/wine/-/commit/fddd7aab7c49d7b833bd07090a03a87...
Author: Alexandre Julliard julliard@winehq.org Date: Fri May 12 11:38:51 2023 +0200
winebuild: Disallow floating point arguments in syscall functions.
---
tools/winebuild/parser.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/tools/winebuild/parser.c b/tools/winebuild/parser.c index 5eed7e22ab0..eaf90a85966 100644 --- a/tools/winebuild/parser.c +++ b/tools/winebuild/parser.c @@ -271,14 +271,20 @@ static int parse_spec_arguments( ORDDEF *odp, DLLSPEC *spec, int optional ) error( "Unknown argument type '%s'\n", token ); return 0; } - if (is_win32) switch (arg) + switch (arg) { case ARG_WORD: case ARG_SWORD: case ARG_SEGPTR: case ARG_SEGSTR: + if (!is_win32) break; error( "Argument type '%s' only allowed for Win16\n", token ); return 0; + case ARG_FLOAT: + case ARG_DOUBLE: + if (!(odp->flags & FLAG_SYSCALL)) break; + error( "Argument type '%s' not allowed for syscall function\n", token ); + return 0; } odp->u.func.args[i] = arg; }