diff options
author | Tiago Salem Herrmann <therrmann@suse.com> | 2017-12-12 13:52:45 -0200 |
---|---|---|
committer | Tiago Salem Herrmann <therrmann@suse.com> | 2017-12-13 15:03:41 -0200 |
commit | 12ec9c309967d663e93254e3fca835f9a240e26f (patch) | |
tree | 81f8d3f5218b972abbea39789ab4a23e7ca825f4 /src/basic/fileio.h | |
parent | a668bfe88a48d433a81dad8219bd98fc73838eda (diff) | |
download | systemd-12ec9c309967d663e93254e3fca835f9a240e26f.tar.gz systemd-12ec9c309967d663e93254e3fca835f9a240e26f.tar.bz2 systemd-12ec9c309967d663e93254e3fca835f9a240e26f.zip |
sysctl: disable buffer while writing to /proc
fputs() writes only first 2048 bytes and fails
to write to /proc when values are larger than that.
This patch adds a new flag to WriteStringFileFlags
that make it possible to disable the buffer under
specific cases.
Diffstat (limited to 'src/basic/fileio.h')
-rw-r--r-- | src/basic/fileio.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/basic/fileio.h b/src/basic/fileio.h index c283f41f09..da5d5c66b5 100644 --- a/src/basic/fileio.h +++ b/src/basic/fileio.h @@ -35,6 +35,7 @@ typedef enum { WRITE_STRING_FILE_AVOID_NEWLINE = 1<<2, WRITE_STRING_FILE_VERIFY_ON_FAILURE = 1<<3, WRITE_STRING_FILE_SYNC = 1<<4, + WRITE_STRING_FILE_DISABLE_BUFFER = 1<<5, /* And before you wonder, why write_string_file_atomic_label_ts() is a separate function instead of just one more flag here: it's about linking: we don't want to pull -lselinux into all users of write_string_file() |