]> git.ipfire.org Git - thirdparty/shadow.git/commitdiff
Avoid multiple statements per line.
authorNicolas François <nicolas.francois@centraliens.net>
Mon, 19 Aug 2013 22:40:17 +0000 (00:40 +0200)
committerNicolas François <nicolas.francois@centraliens.net>
Mon, 19 Aug 2013 23:30:07 +0000 (01:30 +0200)
* src/su.c: Avoid multiple statements per line.

ChangeLog
src/su.c

index a07c4fb514e44b78097ad7dd6fb21ac8bd91065e..9d5dd4cd1a1b8c634c3cf26371d9fb31ff39cc01 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2013-08-19  Nicolas François  <nicolas.francois@centraliens.net>
+
+       * src/su.c: Avoid multiple statements per line.
+
 2013-08-19  Nicolas François  <nicolas.francois@centraliens.net>
 
        * src/su.c: have_tty and winsz_set are booleans.
index a4542df14bd929bbf22efd5247dce1d5a2cd1530..7be5f45852c27a2aef0e855229677f5556842e68 100644 (file)
--- a/src/su.c
+++ b/src/su.c
@@ -308,7 +308,8 @@ static void handle_session (void)
                /*
                 * Open and prepare pseudo terminal master
                 */
-               if ((fd_ptmx = open ("/dev/ptmx", O_RDWR)) == -1) {
+               fd_ptmx = open ("/dev/ptmx", O_RDWR);
+               if (-1 == fd_ptmx) {
                        fprintf (stderr, _("%s: Cannot open pt master\n"), Prog);
                        exit (1);
                }
@@ -324,13 +325,15 @@ static void handle_session (void)
                        exit (1);
                }
 
-               if ((pts_name = ptsname (fd_ptmx)) == NULL) {
+               pts_name = ptsname (fd_ptmx);
+               if (NULL == pts_name) {
                        fprintf (stderr, _("%s: Cannot get pt slave name\n"), Prog);
                        (void) close (fd_ptmx);
                        exit (1);
                }
 
-               if ((fd_pts = open (pts_name, O_RDWR )) == -1) {
+               fd_pts = open (pts_name, O_RDWR );
+               if (-1 == fd_pts) {
                        fprintf (stderr, _("%s: Cannot open pt slave\n"), Prog);
                        (void) close (fd_ptmx);
                        exit (1);