diff options
author | Lennart Poettering <lennart@poettering.net> | 2010-11-18 21:52:26 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2010-11-18 21:52:26 +0100 |
commit | 8e1bd70d4ce6d3881c1df6a6482643a2b3a69bb1 (patch) | |
tree | f4d8acede8d7ca5cdc53bf74ae2af7d80bfc60a9 /src/util.c | |
parent | 40f9afa72117d928ddf3f8887026c74e07f09deb (diff) |
sysctl: implement native sysctl tool to support Debian-style /etc/sysctl.d
Diffstat (limited to 'src/util.c')
-rw-r--r-- | src/util.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/util.c b/src/util.c index 861f9eaa43..0cd78f6561 100644 --- a/src/util.c +++ b/src/util.c @@ -495,6 +495,9 @@ int write_one_line_file(const char *fn, const char *line) { goto finish; } + if (!endswith(line, "\n")) + fputc('\n', f); + r = 0; finish: fclose(f); |