repo: ngircd
action: commit
revision: 
path_from: 
revision_from: 2924b3d52ac2ab89e3bc517a1f664ec056a45edd:
path_to: 
revision_to: 
git.thebackupbox.net
ngircd
git clone git://git.thebackupbox.net/ngircd
commit 2924b3d52ac2ab89e3bc517a1f664ec056a45edd
Author: Alexander Barton 
Date:   Mon Dec 5 23:33:12 2016 +0100

    gcc 6.2 warnings: fix code indentation

    This fixes the following correct -Wmisleading-indentation warning
    messages of gcc 6.2:

    irc-write.c: In function ‘IRC_SendWallops’:
    irc-write.c:521:4: warning: this ‘if’ clause does not guard...
    irc-write.c:524:5: note: ...this statement, but the latter is
      misleadingly indented as if it is guarded by the ‘if’
    irc-write.c:526:4: warning: this ‘if’ clause does not guard... []
    irc-write.c:529:5: note: ...this statement, but the latter is
      misleadingly indented as if it is guarded by the ‘if’

    irc-info.c: In function ‘IRC_STATS’:
    irc-info.c:895:3: warning: this ‘else’ clause does not guard...
    irc-info.c:897:4: note: ...this statement, but the latter is
      misleadingly indented as if it is guarded by the ‘else’

    No functional changes, the code has been correct, but the indentation
    was wrong ...

diff --git a/src/ngircd/irc-info.c b/src/ngircd/irc-info.c
index 1788bf60feebf6e1733b0e92c4070d1f0848250f..
index ..82bd55182d774a54343c4634ae5271032a3aba8c 100644
--- a/src/ngircd/irc-info.c
+++ b/src/ngircd/irc-info.c
@@ -894,16 +894,16 @@ IRC_STATS( CLIENT *Client, REQUEST *Req )
 			list = Class_GetList(CLASS_GLINE);
 		else
 			list = Class_GetList(CLASS_KLINE);
-			list_item = Lists_GetFirst(list);
-			while (list_item) {
-				if (!IRC_WriteStrClient(from, RPL_STATSXLINE_MSG,
+		list_item = Lists_GetFirst(list);
+		while (list_item) {
+			if (!IRC_WriteStrClient(from, RPL_STATSXLINE_MSG,
 						Client_ID(from), query,
 						Lists_GetMask(list_item),
 						Lists_GetValidity(list_item),
 						Lists_GetReason(list_item)))
-					return DISCONNECTED;
-				list_item = Lists_GetNext(list_item);
-			}
+				return DISCONNECTED;
+			list_item = Lists_GetNext(list_item);
+		}
 		break;
 	case 'L':	/* Link status (servers and user links) */
 		if (!Op_Check(from, Req))
diff --git a/src/ngircd/irc-write.c b/src/ngircd/irc-write.c
index 8d09f9bcf8eb271672d32de78199fd18e41e26a3..
index ..92e8cfe39047992bdaff2d700ec192bb24a58483 100644
--- a/src/ngircd/irc-write.c
+++ b/src/ngircd/irc-write.c
@@ -521,12 +521,12 @@ va_dcl
 			if (Client_HasMode(to, 'w'))
 				IRC_WriteStrClientPrefix(to, From,
 							 "WALLOPS :%s", msg);
-				break;
+			break;
 		case CLIENT_SERVER:
 			if (to != Client)
 				IRC_WriteStrClientPrefix(to, From,
 							 "WALLOPS :%s", msg);
-				break;
+			break;
 		}
 	}
 } /* IRC_SendWallops */

-----END OF PAGE-----