chiark / gitweb /
Prep v231: Minor fix for update-utmp
authorSven Eden <yamakuzure@gmx.net>
Wed, 14 Jun 2017 15:21:19 +0000 (17:21 +0200)
committerSven Eden <yamakuzure@gmx.net>
Fri, 16 Jun 2017 08:13:01 +0000 (10:13 +0200)
src/update-utmp/Makefile [changed from file to symlink]
src/update-utmp/update-utmp.c

deleted file mode 100644 (file)
index 9d0750519466eaffcbd2ad91ac5c0e6c4e84bb57..0000000000000000000000000000000000000000
+++ /dev/null
@@ -1,28 +0,0 @@
-#  This file is part of systemd.
-#
-#  Copyright 2010 Lennart Poettering
-#
-#  systemd is free software; you can redistribute it and/or modify it
-#  under the terms of the GNU Lesser General Public License as published by
-#  the Free Software Foundation; either version 2.1 of the License, or
-#  (at your option) any later version.
-#
-#  systemd is distributed in the hope that it will be useful, but
-#  WITHOUT ANY WARRANTY; without even the implied warranty of
-#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#  Lesser General Public License for more details.
-#
-#  You should have received a copy of the GNU Lesser General Public License
-#  along with systemd; If not, see <http://www.gnu.org/licenses/>.
-
-# This file is a dirty trick to simplify compilation from within
-# emacs. This file is not intended to be distributed. So, don't touch
-# it, even better ignore it!
-
-all:
-       $(MAKE) -C ..
-
-clean:
-       $(MAKE) -C .. clean
-
-.PHONY: all clean
new file mode 120000 (symlink)
index 0000000000000000000000000000000000000000..d0b0e8e0086f68062b2b427755eb137285993ed3
--- /dev/null
@@ -0,0 +1 @@
+../Makefile
\ No newline at end of file
index 7162084062fe95f9861322266291b5517ad6406e..655615fc0bf48710460fd097e6beafa6a6594e8e 100644 (file)
 //#include "util.h"
 #include "utmp-wtmp.h"
 
 //#include "util.h"
 #include "utmp-wtmp.h"
 
-/// includes needed by elogind:
+/// Additional includes needed by elogind
 #include "string-util.h"
 #include "time-util.h"
 #include "update-utmp.h"
 #include "string-util.h"
 #include "time-util.h"
 #include "update-utmp.h"
-
-
 typedef struct Context {
         sd_bus *bus;
 #ifdef HAVE_AUDIT
 typedef struct Context {
         sd_bus *bus;
 #ifdef HAVE_AUDIT
@@ -270,7 +268,6 @@ void update_utmp(int argc, char* argv[], sd_bus *bus) {
         if (c.audit_fd < 0 && errno != EAFNOSUPPORT && errno != EPROTONOSUPPORT)
                 log_error_errno(errno, "Failed to connect to audit log: %m");
 #endif
         if (c.audit_fd < 0 && errno != EAFNOSUPPORT && errno != EPROTONOSUPPORT)
                 log_error_errno(errno, "Failed to connect to audit log: %m");
 #endif
-
 #if 0 /// UNNEEDED by elogind
         r = bus_connect_system_systemd(&c.bus);
         if (r < 0) {
 #if 0 /// UNNEEDED by elogind
         r = bus_connect_system_systemd(&c.bus);
         if (r < 0) {
@@ -302,14 +299,12 @@ finish:
         else if (streq(argv[1], "shutdown"))
                 (void)on_shutdown(&c);
 #endif // 0
         else if (streq(argv[1], "shutdown"))
                 (void)on_shutdown(&c);
 #endif // 0
-
 #ifdef HAVE_AUDIT
         if (c.audit_fd >= 0)
                 audit_close(c.audit_fd);
 #endif
 
         sd_bus_flush_close_unref(c.bus);
 #ifdef HAVE_AUDIT
         if (c.audit_fd >= 0)
                 audit_close(c.audit_fd);
 #endif
 
         sd_bus_flush_close_unref(c.bus);
-
 #if 0 /// UNNEEDED by elogind
         return r < 0 ? EXIT_FAILURE : EXIT_SUCCESS;
 #endif // 0
 #if 0 /// UNNEEDED by elogind
         return r < 0 ? EXIT_FAILURE : EXIT_SUCCESS;
 #endif // 0