diff options
Diffstat (limited to 'src/gpasswd.c')
-rw-r--r-- | src/gpasswd.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/gpasswd.c b/src/gpasswd.c index 4d75af96..a43d9a59 100644 --- a/src/gpasswd.c +++ b/src/gpasswd.c @@ -58,6 +58,7 @@ */ /* The name of this command, as it is invoked */ const char *Prog; +FILE *shadow_logfd = NULL; #ifdef SHADOWGRP /* Indicate if shadow groups are enabled on the system @@ -988,6 +989,7 @@ int main (int argc, char **argv) */ bywho = getuid (); Prog = Basename (argv[0]); + shadow_logfd = stderr; OPENLOG ("gpasswd"); setbuf (stdout, NULL); @@ -1204,6 +1206,17 @@ int main (int argc, char **argv) nscd_flush_cache ("group"); sssd_flush_cache (SSSD_DB_GROUP); +#ifdef SHADOWGRP + if (sgent.sg_adm) { + xfree(sgent.sg_adm); + } + if (sgent.sg_mem) { + xfree(sgent.sg_mem); + } +#endif + if (grent.gr_mem) { + xfree(grent.gr_mem); + } exit (E_SUCCESS); } |