Vitaliy Margolen : advapi32: Don't allocate memory for empty argument string and pass
Module: wine Branch: refs/heads/master Commit: e74bda9d958fdf416c0453cf9b363e96aef6a02a URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=e74bda9d958fdf416c0453cf... Author: Vitaliy Margolen <wine-patch(a)kievinfo.com> Date: Tue Jan 3 12:05:32 2006 +0100 advapi32: Don't allocate memory for empty argument string and pass NULL instead. --- dlls/advapi32/service.c | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/dlls/advapi32/service.c b/dlls/advapi32/service.c index cc6a36c..60d0f8d 100644 --- a/dlls/advapi32/service.c +++ b/dlls/advapi32/service.c @@ -359,6 +359,15 @@ static DWORD WINAPI service_thread(LPVOI len += strlenW(&str[len]) + 1; argc++; } + + if (!argc) + { + if (info->unicode) + info->proc.w(0, NULL); + else + info->proc.a(0, NULL); + return 0; + } if (info->unicode) {
participants (1)
-
Alexandre Julliard