Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit eacd121c authored by Vasiliy Kulikov's avatar Vasiliy Kulikov Committed by Greg Kroah-Hartman
Browse files

staging: vt6656: implement missing brackets



Identation says that copy_to_user() should be called only iff
wrq->u.essid.pointer is not zero.  Also it is useless to call copy_to_user(0, ...).

Signed-off-by: default avatarVasiliy Kulikov <segooon@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 705059a6
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1675,7 +1675,7 @@ static int device_ioctl(struct net_device *dev, struct ifreq *rq, int cmd) {

		{
			char essid[IW_ESSID_MAX_SIZE+1];
			if (wrq->u.essid.pointer)
			if (wrq->u.essid.pointer) {
				rc = iwctl_giwessid(dev, NULL,
						    &(wrq->u.essid), essid);
				if (copy_to_user(wrq->u.essid.pointer,
@@ -1683,6 +1683,7 @@ static int device_ioctl(struct net_device *dev, struct ifreq *rq, int cmd) {
						         wrq->u.essid.length) )
					rc = -EFAULT;
			}
		}
		break;

	case SIOCSIWAP: