[Patch 6/7] tabled: unsigned < 0

Pete Zaitcev <[email protected]>
Newsgroups org.kernel.vger.hail-devel
Message-ID <[email protected]>
Enums and sizeofs are unsigned. V. annoying because of int i;.

Signed-off-by: Pete Zaitcev <[email protected]>

---
 server/status.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -urp -X dontdiff tabled-m/server/status.c tabled-tip/server/status.c
--- tabled-m/server/status.c	2010-04-01 19:13:05.000000000 -0600
+++ tabled-tip/server/status.c	2010-04-01 17:55:46.000000000 -0600
@@ -74,7 +74,7 @@ static bool stat_err(struct client *cli,
 	 * We do not use all codes that the main server can return,
 	 * so our array is smaller and it has gaps. Must check, in case.
 	 */
-	if (code < 0 || code >= ARRAY_SIZE(err_info) || !err_info[code].code) {
+	if (code >= ARRAY_SIZE(err_info) || !err_info[code].code) {
 		applog(LOG_INFO, "client %s status error %d",
 		       cli->addr_host, code);
 		code = InternalError;
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.