]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
localed: don't remove xorg.conf.d/00-keyboard.conf on failures
authorAlan Jenkins <alan.christopher.jenkins@gmail.com>
Thu, 17 Aug 2017 16:21:34 +0000 (17:21 +0100)
committerAlan Jenkins <alan.christopher.jenkins@gmail.com>
Thu, 17 Aug 2017 16:21:47 +0000 (17:21 +0100)
One of the benefits of updating a file "atomically", is to avoid losing the
old version.  For example, if we run out of disk space half-way through.

Fix localed to enjoy this benefit.

src/locale/keymap-util.c

index ec48e8ba6d5ff709586061959b2532fece06a384..5cefeb6135ddefac22c8dc76a5658f69e092dcd3 100644 (file)
@@ -394,8 +394,6 @@ int x11_write_data(Context *c) {
         return 0;
 
 fail:
-        (void) unlink("/etc/X11/xorg.conf.d/00-keyboard.conf");
-
         if (temp_path)
                 (void) unlink(temp_path);