diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2011-07-29 15:19:20 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2011-08-02 15:09:32 +1000 |
commit | e53ce3e6f590bc575a732c97acafdc7803bacae3 (patch) | |
tree | 33e7d1ecbafb4c7787395a8fbf4711191398823b /XOrg | |
parent | a0f848fe7206a470e11a0bc87ad739f5aef76137 (diff) |
XOrg: return errors when writing to config file
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'XOrg')
-rw-r--r-- | XOrg/ConfigGenerator.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/XOrg/ConfigGenerator.pm b/XOrg/ConfigGenerator.pm index 4959f2e..a136113 100644 --- a/XOrg/ConfigGenerator.pm +++ b/XOrg/ConfigGenerator.pm @@ -56,9 +56,10 @@ sub save { $filename = $self->DEFAULT_CONFIG_FILE if not defined $filename; } - open FILE, "> $filename"; + open FILE, "> $filename" or return 0; print FILE $self->print; close FILE; + return 1; } |