diff options
author | Brian Cameron <brian.cameron@sun.com> | 2006-10-06 00:54:44 +0000 |
---|---|---|
committer | Brian Cameron <bcameron@src.gnome.org> | 2006-10-06 00:54:44 +0000 |
commit | e6acd87e7931ac95405d1ba026b3f9dacb66669f (patch) | |
tree | d339a8e19217fef5090845cb7340e308691a70b6 /daemon | |
parent | 09b8bfee9796935adac368a8ecccdddaffeb9ff2 (diff) | |
download | gdm-e6acd87e7931ac95405d1ba026b3f9dacb66669f.tar.gz |
Set authdir to NULL after freeing to avoid accessing an invalid pointer.
2006-10-05 Brian Cameron <brian.cameron@sun.com>
* daemon/auth.c: Set authdir to NULL after freeing to avoid accessing
an invalid pointer. Fixes bug #359831. Patch provided by
Amnon Aaronsohn <bla@cs.huji.ac.il>.
Diffstat (limited to 'daemon')
-rw-r--r-- | daemon/auth.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/daemon/auth.c b/daemon/auth.c index f5fae30d..acf0f3fb 100644 --- a/daemon/auth.c +++ b/daemon/auth.c @@ -710,7 +710,9 @@ try_user_add_again: af = gdm_safe_fopen_ap (d->userauth); } + /* Set to NULL, because can goto try_user_add_again. g_free (authdir); + authdir = NULL; if G_UNLIKELY (af == NULL) { /* Really no need to clean up here - this process is a goner anyway */ |