mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-11-20 00:26:39 +08:00
Fix the conflict between rwpidforward and rw mount options
Both these options are started with "rw" - that's why the first one isn't switched on even if it is specified. Fix this by adding a length check for "rw" option check. Cc: <stable@kernel.org> Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Steve French <sfrench@us.ibm.com>
This commit is contained in:
parent
5b980b0121
commit
c9c7fa0064
@ -1298,7 +1298,7 @@ cifs_parse_mount_options(const char *mountdata, const char *devname,
|
||||
/* ignore */
|
||||
} else if (strnicmp(data, "guest", 5) == 0) {
|
||||
/* ignore */
|
||||
} else if (strnicmp(data, "rw", 2) == 0) {
|
||||
} else if (strnicmp(data, "rw", 2) == 0 && strlen(data) == 2) {
|
||||
/* ignore */
|
||||
} else if (strnicmp(data, "ro", 2) == 0) {
|
||||
/* ignore */
|
||||
@ -1401,7 +1401,7 @@ cifs_parse_mount_options(const char *mountdata, const char *devname,
|
||||
vol->server_ino = 1;
|
||||
} else if (strnicmp(data, "noserverino", 9) == 0) {
|
||||
vol->server_ino = 0;
|
||||
} else if (strnicmp(data, "rwpidforward", 4) == 0) {
|
||||
} else if (strnicmp(data, "rwpidforward", 12) == 0) {
|
||||
vol->rwpidforward = 1;
|
||||
} else if (strnicmp(data, "cifsacl", 7) == 0) {
|
||||
vol->cifs_acl = 1;
|
||||
|
Loading…
Reference in New Issue
Block a user