wlantest: Remove unnecessary validation code

This condition is already checked above when figuring out whether a key
is known and as such, there is no point in keeping this check here.
This commit is contained in:
Jouni Malinen 2010-12-17 08:16:12 +02:00
parent ef00c78097
commit cb384549e2

View file

@ -351,12 +351,6 @@ int wlantest_inject(struct wlantest *wt, struct wlantest_bss *bss,
} }
} }
if ((prot == WLANTEST_INJECT_PROTECTED ||
prot == WLANTEST_INJECT_INCORRECT_KEY) && !protect) {
wpa_printf(MSG_INFO, "Cannot protect injected frame");
return -1;
}
if (protect) if (protect)
return wlantest_inject_prot( return wlantest_inject_prot(
wt, bss, sta, frame, len, wt, bss, sta, frame, len,