]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
last: clean up the begin of the file
authorKarel Zak <kzak@redhat.com>
Mon, 12 Aug 2013 10:26:03 +0000 (12:26 +0200)
committerKarel Zak <kzak@redhat.com>
Mon, 12 Aug 2013 10:26:03 +0000 (12:26 +0200)
 .. and improve last(1) stuff in configure script.

Signed-off-by: Karel Zak <kzak@redhat.com>
AUTHORS
configure.ac
login-utils/last.c

diff --git a/AUTHORS b/AUTHORS
index 5e3c44ba302f341fc9f309417ce72b4883c1c26d..789d65e705c695df79deb54a23610ad0d051d5ac 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -27,6 +27,8 @@ AUTHORS (merged projects & commands):
       getopt:          Frodo Looijaard <frodol@dds.nl>
       hwclock:         Bryan Henderson <bryanh@giraffe-data.com>
       ipcmk:           Hayden James <hayden.james@gmail.com>
+      last/lastb:      [merged from sysvinit]
+                       Miquel van Smoorenburg <miquels@cistron.nl>
       ldattach:        Tilman Schmidt <tilman@imap.cc>
       libblkid:        [merged from e2fsprogs]
                        Theodore Ts'o <tytso@mit.edu>
index d0c54247fb61b3b418b023b9fe9f3125d4139541..87cffadd29a881ec0560eb323f8dffc35e56fdaa 100644 (file)
@@ -1066,15 +1066,15 @@ AC_ARG_ENABLE([deprecated-last],
   [], [enable_deprecated_last=no]
 )
 UL_BUILD_INIT([deprecated_last])
-UL_CONFLICTS_BUILD([last], [deprecated_last], [old deprecated last version])
 AM_CONDITIONAL([BUILD_DEPRECATED_LAST], [test "x$build_deprecated_last" = xyes])
 
 
 AC_ARG_ENABLE([last],
   AS_HELP_STRING([--disable-last], [do not build last]),
-  [], [enable_last=yes]
+  [], [enable_last=check]
 )
 UL_BUILD_INIT([last])
+UL_CONFLICTS_BUILD([last], [deprecated_last], [old deprecated last version])
 AM_CONDITIONAL([BUILD_LAST], [test "x$build_last" = xyes])
 
 
index 06017df15e4db1168b2b94377b7164d1189c3a6d..fb786f41e5096c2a1dd7ae88eb09c773975ff34d 100644 (file)
@@ -1,36 +1,28 @@
 /*
- * last.c      Re-implementation of the 'last' command, this time
- *             for Linux. Yes I know there is BSD last, but I
- *             just felt like writing this. No thanks :-).
- *             Also, this version gives lots more info (especially with -x)
+ * last(1) from sysvinit project, merged into util-linux in Aug 2013.
  *
- * Author:     Miquel van Smoorenburg, miquels@cistron.nl
+ * Copyright (C) 1991-2004 Miquel van Smoorenburg.
+ * Copyright (C) 2013      Ondrej Oprala <ooprala@redhat.com>
  *
- * Version:    @(#)last  2.85  30-Jul-2004  miquels@cistron.nl
+ * Re-implementation of the 'last' command, this time for Linux. Yes I know
+ * there is BSD last, but I just felt like writing this. No thanks :-).  Also,
+ * this version gives lots more info (especially with -x)
  *
- *             This file is part of the sysvinit suite,
- *             Copyright (C) 1991-2004 Miquel van Smoorenburg.
  *
- *             This program is free software; you can redistribute it and/or modify
- *             it under the terms of the GNU General Public License as published by
- *             the Free Software Foundation; either version 2 of the License, or
- *             (at your option) any later version.
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
  *
- *             This program 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 General Public License for more details.
+ * This program 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 General Public License for more details.
  *
- *             You should have received a copy of the GNU General Public License
- *             along with this program; if not, write to the Free Software
- *             Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
-
-/*              Deleting the -o option as well as any related code (utmp libc5 support),
- *              declaring functions static and fixing a few warnings(sighandlers)
- *              06-Aug-2013 Ondrej Oprala <ooprala@redhat.com>
- */
-
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <sys/fcntl.h>
 #include <arpa/inet.h>
 
 #ifndef SHUTDOWN_TIME
-#  define SHUTDOWN_TIME 254
+# define SHUTDOWN_TIME 254
 #endif
 
-char *Version = "@(#) last 2.85 31-Apr-2004 miquels";
-
 #define CHOP_DOMAIN    0       /* Define to chop off local domainname. */
 #define UCHUNKSIZE     16384   /* How much we read at once. */
 
 /* Double linked list of struct utmp's */
 struct utmplist {
-  struct utmp ut;
-  struct utmplist *next;
-  struct utmplist *prev;
+       struct utmp ut;
+       struct utmplist *next;
+       struct utmplist *prev;
 };
 struct utmplist *utmplist = NULL;