afsd: look in the right place for -splitcache argument
authorGarrett Wollman <wollman@csail.mit.edu>
Sun, 7 Aug 2011 04:35:36 +0000 (00:35 -0400)
committerDerrick Brashear <shadow@dementia.org>
Sun, 7 Aug 2011 18:50:27 +0000 (11:50 -0700)
The argument to -splitcache is in as->parms[34], not [30].

Change-Id: I4d7be16a1ad99a03025c80f9782c4f678da868ae
Found-by: clang static analyzer
Reviewed-on: http://gerrit.openafs.org/5169
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Simon Wilkinson <sxw@inf.ed.ac.uk>
Reviewed-by: Derrick Brashear <shadow@dementia.org>

src/afsd/afsd.c

index 16d3451..9576e40 100644 (file)
@@ -1870,7 +1870,7 @@ mainproc(struct cmd_syndesc *as, void *arock)
        else {
            ropct = atoi((char *)c + 1);
            *c = '\0';
-           rwpct = atoi((char *)as->parms[30].items->data);
+           rwpct = atoi((char *)as->parms[34].items->data);
            if ((rwpct != 0) && (ropct != 0) && (ropct + rwpct == 100)) {
                /* -splitcache */
                enable_splitcache = 1;