aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvda <vda@69ca8d6d-28ef-0310-b511-8ec308f3f277>2007-05-09 20:38:04 +0000
committervda <vda@69ca8d6d-28ef-0310-b511-8ec308f3f277>2007-05-09 20:38:04 +0000
commit84fe510bef96554da6fe462a12d0a91023812982 (patch)
tree6ea1fc6ef4696f9b425074f1fe8e0c96edb98184
parent5cda2aab7576b9cbf2aea01d6db60897368014be (diff)
downloadbusybox-w32-84fe510bef96554da6fe462a12d0a91023812982.tar.gz
busybox-w32-84fe510bef96554da6fe462a12d0a91023812982.tar.bz2
busybox-w32-84fe510bef96554da6fe462a12d0a91023812982.zip
mount: fix incorrect usage of strtok (inadvertently used NULL sometimes).
the change is "for(xxx)...." -> "if(var) for(xxx)...", but my gcc 4.1.2 adds _158 bytes_!! WTF?? 8( git-svn-id: svn://busybox.net/trunk/busybox@18594 69ca8d6d-28ef-0310-b511-8ec308f3f277
-rw-r--r--util-linux/mount.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c
index 7dd70392a..b76c38ab1 100644
--- a/util-linux/mount.c
+++ b/util-linux/mount.c
@@ -886,8 +886,7 @@ static int nfsmount(struct mntent *mp, int vfsflags, char *filteropts)
886 nfsvers = 0; 886 nfsvers = 0;
887 887
888 /* parse options */ 888 /* parse options */
889 889 if (filteropts) for (opt = strtok(filteropts, ","); opt; opt = strtok(NULL, ",")) {
890 for (opt = strtok(filteropts, ","); opt; opt = strtok(NULL, ",")) {
891 char *opteq = strchr(opt, '='); 890 char *opteq = strchr(opt, '=');
892 if (opteq) { 891 if (opteq) {
893 static const char *const options[] = { 892 static const char *const options[] = {