WIP: update tizen_qemu_defconfig
[platform/kernel/linux-starfive.git] / fs / fs_context.c
index 24ce12f..851214d 100644 (file)
@@ -561,7 +561,8 @@ static int legacy_parse_param(struct fs_context *fc, struct fs_parameter *param)
                        return -ENOMEM;
        }
 
-       ctx->legacy_data[size++] = ',';
+       if (size)
+               ctx->legacy_data[size++] = ',';
        len = strlen(param->key);
        memcpy(ctx->legacy_data + size, param->key, len);
        size += len;