mac80211: silently accept deletion of non-existant key

Otherwise, 'iwconfig wlan0 key off' with no key set results in:

	Error for wireless request "Set Encode" (8B2A) :
	    SET failed on device wlan0 ; No such file or directory.

Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
John W. Linville 2008-03-25 11:43:15 -04:00 committed by John W. Linville
parent 5983a3dff0
commit be892471c4

View file

@ -55,9 +55,6 @@ static int ieee80211_set_encryption(struct net_device *dev, u8 *sta_addr,
key = sta->key;
}
if (!key)
return -ENOENT;
ieee80211_key_free(key);
return 0;
} else {