|
@@ -780,8 +780,10 @@ static int ioctl_standard_iw_point(struct iw_point *iwp, unsigned int cmd,
|
|
|
if (cmd == SIOCSIWENCODEEXT) {
|
|
if (cmd == SIOCSIWENCODEEXT) {
|
|
|
struct iw_encode_ext *ee = (void *) extra;
|
|
struct iw_encode_ext *ee = (void *) extra;
|
|
|
|
|
|
|
|
- if (iwp->length < sizeof(*ee) + ee->key_len)
|
|
|
|
|
- return -EFAULT;
|
|
|
|
|
|
|
+ if (iwp->length < sizeof(*ee) + ee->key_len) {
|
|
|
|
|
+ err = -EFAULT;
|
|
|
|
|
+ goto out;
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|