You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Christoph von Wittich <Ch...@ApiViewer.de> on 2007/10/09 02:42:35 UTC

bugfix



Index: misc/win32/start.c
===================================================================
--- misc/win32/start.c	(revision 582662)
+++ misc/win32/start.c	(working copy)
@@ -124,7 +124,7 @@
             wstrs = CommandLineToArgvW(sysstr, &wstrc);
             if (wstrs) {
                 *argc = apr_wastrtoastr(argv, wstrs, wstrc);
-                GlobalFree(wstrs);
+                LocalFree(wstrs);
             }
         }


Re: bugfix

Posted by "William A. Rowe, Jr." <wr...@rowe-clan.net>.
Christoph von Wittich wrote:
> 
> Index: misc/win32/start.c
> ===================================================================
> --- misc/win32/start.c	(revision 582662)
> +++ misc/win32/start.c	(working copy)
> @@ -124,7 +124,7 @@
>              wstrs = CommandLineToArgvW(sysstr, &wstrc);
>              if (wstrs) {
>                  *argc = apr_wastrtoastr(argv, wstrs, wstrc);
> -                GlobalFree(wstrs);
> +                LocalFree(wstrs);
>              }
>          }

I concur the current http://msdn2.microsoft.com/en-us/library/ms647232.aspx
validates your comment, thanks.  Did you actually observe an error, and if
so would you provide details?  Bug fixes without describing the bug itself
are generally ignored.

Remember this code goes from Win9x to (conceivably) Windows 2008, I've yet
to see a fault (although as you see, there's never been error checking here,
either).  For a good while there was no different on Global/Local frees but
I expect that will change (again) as win32 evolves.

Bill