James Larrowe : winebuild: Fix a segmentation fault.
Alexandre Julliard
julliard at winehq.org
Mon Jan 14 16:21:49 CST 2019
Module: wine
Branch: master
Commit: f97636bc494bef29073ed441e27ca8bd1f89c178
URL: https://source.winehq.org/git/wine.git/?a=commit;h=f97636bc494bef29073ed441e27ca8bd1f89c178
Author: James Larrowe <larrowe.semaj11 at gmail.com>
Date: Sat Jan 12 17:01:08 2019 -0500
winebuild: Fix a segmentation fault.
When 'winebuild' is called with no arguments, the make_c_identifier
function is passed a null pointer, which is dereferenced and causes
a segmentation fault.
Signed-off-by: James Larrowe <larrowe.semaj11 at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
tools/winebuild/main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/winebuild/main.c b/tools/winebuild/main.c
index 70f381c..b2f5c95 100644
--- a/tools/winebuild/main.c
+++ b/tools/winebuild/main.c
@@ -164,7 +164,7 @@ static void init_dll_name( DLLSPEC *spec )
spec->dll_name = xstrdup( spec->file_name );
if ((p = strrchr( spec->dll_name, '.' ))) *p = 0;
}
- spec->c_name = make_c_identifier( spec->dll_name );
+ if (spec->dll_name) spec->c_name = make_c_identifier( spec->dll_name );
}
/* set the dll subsystem */
More information about the wine-cvs
mailing list