Skip to content

Commit 353b5a9

Browse files
Prasad J Panditgkurz
authored andcommitted
9p: null terminate fs driver options list
NULL terminate fs driver options' list, validate_opt() looks for a null entry to terminate the loop. Fixes: aee7f3e ("fsdev: Error out when unsupported option is passed") Signed-off-by: Prasad J Pandit <[email protected]> Reviewed-by: Li Qiang <[email protected]> Message-Id: <[email protected]> Signed-off-by: Greg Kurz <[email protected]>
1 parent b6d7e9b commit 353b5a9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

fsdev/qemu-fsdev.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,13 +78,15 @@ static FsDriverTable FsDrivers[] = {
7878
"throttling.iops-read-max-length",
7979
"throttling.iops-write-max-length",
8080
"throttling.iops-size",
81+
NULL
8182
},
8283
},
8384
{
8485
.name = "synth",
8586
.ops = &synth_ops,
8687
.opts = (const char * []) {
8788
COMMON_FS_DRIVER_OPTIONS,
89+
NULL
8890
},
8991
},
9092
{
@@ -95,6 +97,7 @@ static FsDriverTable FsDrivers[] = {
9597
"socket",
9698
"sock_fd",
9799
"writeout",
100+
NULL
98101
},
99102
},
100103
};

0 commit comments

Comments
 (0)