]> git.decadent.org.uk Git - nfs-utils.git/commitdiff
mount.nfs: Eliminate compiler warning in utils/mount/parse_opt.c
authorChuck Lever <chuck.lever@oracle.com>
Wed, 13 Oct 2010 15:59:30 +0000 (11:59 -0400)
committerSteve Dickson <steved@redhat.com>
Thu, 14 Oct 2010 14:26:59 +0000 (10:26 -0400)
parse_opt.c: In function po_rightmost:
parse_opt.c:517: warning: conversion to int from unsigned int may
    change the sign of the result

"i" contains the function's result value, so it should be defined as
the same type as the function's return type.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
utils/mount/parse_opt.c

index f0918f7fe264063caa59c23ad438bff2b2720693..ab869d901d12ba66d0b26b1ac46a23e0d5d90f4e 100644 (file)
@@ -508,7 +508,7 @@ po_found_t po_get_numeric(struct mount_options *options, char *keyword, long *va
 int po_rightmost(struct mount_options *options, const char *keys[])
 {
        struct mount_option *option;
-       unsigned int i;
+       int i;
 
        if (options) {
                for (option = options->tail; option; option = option->prev) {