Fwd: PATCH xdm master

Alan Coopersmith alan.coopersmith at oracle.com
Mon Feb 18 01:15:20 UTC 2019


On 05/ 5/16 12:38 AM, David CARLIER wrote:
> This is a tiny patch which fixes a couple of small memory leaks.

Thanks for your contribution, and sorry for the excessive delay in responding,
as few people have time for xdm these days.

I've applied the first two fixes:

https://gitlab.freedesktop.org/xorg/app/xdm/commit/42ae3d66283a9efa0c510d5d438f821549656fe6
https://gitlab.freedesktop.org/xorg/app/xdm/commit/dd7402c2f1e828cc3b0fae036b62f74b8014814b

but not the third:

> @@ -960,6 +960,7 @@ execute (char **argv, char **environ)
>  	    ;
>  	Debug ("Attempting to execve() %s\n", newargv[0]);
>  	execve (newargv[0], newargv, environ);
> +	free(newargv);
>      }
>  }

If we ever get to that point, the exec has failed and we should be
exiting, not just freeing one string.  (Which in fact, we do in the
calling functions, just not right here.)


-- 
	-Alan Coopersmith-               alan.coopersmith at oracle.com
	 Oracle Solaris Engineering - https://blogs.oracle.com/alanc


More information about the xorg-devel mailing list