We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cc3b029 commit 9a56dbfCopy full SHA for 9a56dbf
net/netfilter/xt_LED.c
@@ -110,7 +110,9 @@ static int led_tg_check(const struct xt_tgchk_param *par)
110
struct xt_led_info_internal *ledinternal;
111
int err;
112
113
- if (ledinfo->id[0] == '\0') {
+ /* Bail out if empty string or not a string at all. */
114
+ if (ledinfo->id[0] == '\0' ||
115
+ !memchr(ledinfo->id, '\0', sizeof(ledinfo->id))) {
116
pr_info("No 'id' parameter given.\n");
117
return -EINVAL;
118
}
0 commit comments