summaryrefslogtreecommitdiff
path: root/src/passwd/putgrent.c
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2013-11-04 23:34:21 -0800
committerRich Felker <dalias@aerifal.cx>2013-11-23 16:20:56 -0500
commit3fd1acbfeed025ac833b4d6d2bc45dac4d3562c8 (patch)
tree82f827a7d61da39afbf7f1eec32fd3c77c4700ed /src/passwd/putgrent.c
parenta3b98a11a9b51801109ad46df2a44ee2ee03e37e (diff)
downloadmusl-3fd1acbfeed025ac833b4d6d2bc45dac4d3562c8.tar.gz
musl-3fd1acbfeed025ac833b4d6d2bc45dac4d3562c8.tar.bz2
musl-3fd1acbfeed025ac833b4d6d2bc45dac4d3562c8.tar.xz
musl-3fd1acbfeed025ac833b4d6d2bc45dac4d3562c8.zip
putgrent: Add missing newline
Diffstat (limited to 'src/passwd/putgrent.c')
-rw-r--r--src/passwd/putgrent.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/passwd/putgrent.c b/src/passwd/putgrent.c
index b34f3254..6f26c051 100644
--- a/src/passwd/putgrent.c
+++ b/src/passwd/putgrent.c
@@ -9,6 +9,7 @@ int putgrent(const struct group *gr, FILE *f)
if ((r = fprintf(f, "%s:%s:%d:", gr->gr_name, gr->gr_passwd, gr->gr_gid))<0) goto done;
if (gr->gr_mem) for (i=0; gr->gr_mem[i]; i++)
if ((r = fprintf(f, "%s%s", i?",":"", gr->gr_mem[i]))<0) goto done;
+ r = fputc('\n', f);
done:
funlockfile(f);
return r<0 ? -1 : 0;