summaryrefslogtreecommitdiffstats
path: root/fs/cifs
diff options
context:
space:
mode:
authorDan Carpenter <error27@gmail.com>2010-10-25 07:02:56 +0200
committerSteve French <sfrench@us.ibm.com>2010-10-26 18:22:38 +0000
commitb235f371a2572d7c86a121d96d889eee02ed00e2 (patch)
tree72ae25c83a6ba59926a599e28d47b67bfa0ad863 /fs/cifs
parent21e733930be6458e0c33482b6783e7c15ba984eb (diff)
downloadblackbird-op-linux-b235f371a2572d7c86a121d96d889eee02ed00e2.tar.gz
blackbird-op-linux-b235f371a2572d7c86a121d96d889eee02ed00e2.zip
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 <jlayton@samba.org> Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs')
-rw-r--r--fs/cifs/connect.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c
index c5807d39dced..dd9a4ae1d21d 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);
OpenPOWER on IntegriCloud