|
@@ -1648,6 +1648,13 @@ cifs_parse_mount_options(const char *mountdata, const char *devname,
|
|
|
goto cifs_parse_mount_err;
|
|
|
}
|
|
|
|
|
|
+ vol->UNC = kmalloc(temp_len+1, GFP_KERNEL);
|
|
|
+ if (vol->UNC == NULL) {
|
|
|
+ printk(KERN_WARNING "CIFS: no memory for UNC\n");
|
|
|
+ goto cifs_parse_mount_err;
|
|
|
+ }
|
|
|
+ strcpy(vol->UNC, string);
|
|
|
+
|
|
|
if (strncmp(string, "//", 2) == 0) {
|
|
|
vol->UNC[0] = '\\';
|
|
|
vol->UNC[1] = '\\';
|
|
@@ -1657,13 +1664,6 @@ cifs_parse_mount_options(const char *mountdata, const char *devname,
|
|
|
goto cifs_parse_mount_err;
|
|
|
}
|
|
|
|
|
|
- vol->UNC = kmalloc(temp_len+1, GFP_KERNEL);
|
|
|
- if (vol->UNC == NULL) {
|
|
|
- printk(KERN_WARNING "CIFS: no memory "
|
|
|
- "for UNC\n");
|
|
|
- goto cifs_parse_mount_err;
|
|
|
- }
|
|
|
- strcpy(vol->UNC, string);
|
|
|
break;
|
|
|
case Opt_domain:
|
|
|
string = match_strdup(args);
|