tree-wide: fix write_string_file() user that should not create files

The latest consolidation cleanup of write_string_file() revealed some users
of that helper which should have used write_string_file_no_create() in the
past but didn't. Basically, all existing users that write to files in /sys
and /proc should not expect to write to a file which is not yet existant.
This commit is contained in:
Daniel Mack
2015-07-06 19:27:20 -04:00
parent 4c1fc3e404
commit ad118bda15
7 changed files with 11 additions and 11 deletions
+1 -1
View File
@@ -139,7 +139,7 @@ int mac_smack_apply_pid(pid_t pid, const char *label) {
return 0;
p = procfs_file_alloca(pid, "attr/current");
r = write_string_file(p, label, WRITE_STRING_FILE_CREATE);
r = write_string_file(p, label, 0);
if (r < 0)
return r;
#endif