From b235f371a2572d7c86a121d96d889eee02ed00e2 Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Mon, 25 Oct 2010 07:02:56 +0200 Subject: cifs: cifs_convert_address() returns zero on error The cifs_convert_address() returns zero on error but this caller is testing for negative returns. Btw. "i" is unsigned here, so it's never negative. Reviewed-by: Jeff Layton Signed-off-by: Dan Carpenter Signed-off-by: Steve French diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c index c5807d3..dd9a4ae 100644 --- a/fs/cifs/connect.c +++ b/fs/cifs/connect.c @@ -1067,7 +1067,7 @@ cifs_parse_mount_options(char *options, const char *devname, } i = cifs_convert_address((struct sockaddr *)&vol->srcaddr, value, strlen(value)); - if (i < 0) { + if (i == 0) { printk(KERN_WARNING "CIFS: Could not parse" " srcaddr: %s\n", value); -- cgit v0.10.2