From 7012e2589fcc24d8cc26c2cb757d3aff8660e533 Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Sat, 28 May 2016 22:54:00 +0300 Subject: [PATCH] Remove dead code from wpas_sched_scan_plans_set() scan_plan->interval was checked against 0 twice; the latter case cannot happen. Signed-off-by: Jouni Malinen --- wpa_supplicant/scan.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/wpa_supplicant/scan.c b/wpa_supplicant/scan.c index 40469cae1..787d4e653 100644 --- a/wpa_supplicant/scan.c +++ b/wpa_supplicant/scan.c @@ -2607,13 +2607,6 @@ int wpas_sched_scan_plans_set(struct wpa_supplicant *wpa_s, const char *cmd) goto fail; } - if (!scan_plan->interval) { - wpa_printf(MSG_ERROR, - "scan plan %u: Interval cannot be zero", - num); - goto fail; - } - if (scan_plan->interval > wpa_s->max_sched_scan_plan_interval) { wpa_printf(MSG_WARNING, "scan plan %u: Scan interval too long(%u), use the maximum allowed(%u)",