]> git.ipfire.org Git - thirdparty/shadow.git/commitdiff
lib/port.c: getportent(): Align variables
authorAlejandro Colomar <alx@kernel.org>
Tue, 2 Jul 2024 16:37:57 +0000 (18:37 +0200)
committerSerge Hallyn <serge@hallyn.com>
Sat, 6 Jul 2024 12:44:02 +0000 (07:44 -0500)
Signed-off-by: Alejandro Colomar <alx@kernel.org>
lib/port.c

index 60ec920bda5e985457cd90f9226344ad297fcbab..23b9a1b625723505e4e459b3b96a551ac4680d6b 100644 (file)
@@ -94,17 +94,21 @@ static void endportent (void)
  *     set to EINVAL on error to distinguish the two conditions.
  */
 
-static struct port *getportent (void)
+static struct port *
+getportent(void)
 {
-       static struct port port;        /* static struct to point to         */
-       static char buf[BUFSIZ];        /* some space for stuff              */
-       static char *ttys[PORT_TTY + 1];        /* some pointers to tty names     */
-       static char *users[PORT_IDS + 1];       /* some pointers to user ids     */
-       static struct pt_time ptimes[PORT_TIMES + 1];   /* time ranges         */
-       char *cp;               /* pointer into line                 */
-       int dtime;              /* scratch time of day               */
-       int i, j;
-       int saveerr = errno;    /* errno value on entry              */
+       int   dtime;
+       int   i, j;
+       int   saveerr;
+       char  *cp;
+
+       static char            buf[BUFSIZ];
+       static char            *ttys[PORT_TTY + 1];
+       static char            *users[PORT_IDS + 1];
+       static struct port     port;
+       static struct pt_time  ptimes[PORT_TIMES + 1];
+
+       saveerr = errno;
 
        /*
         * If the ports file is not open, open the file.  Do not rewind