[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20131105.235107.712124797485310428.davem@davemloft.net>
Date: Tue, 05 Nov 2013 23:51:07 -0500 (EST)
From: David Miller <davem@...emloft.net>
To: blaschka@...ux.vnet.ibm.com
Cc: netdev@...r.kernel.org, stable@...r.kernel.org
Subject: Re: [PATCH net] qeth: avoid buffer overflow in snmp ioctl
From: Frank Blaschka <blaschka@...ux.vnet.ibm.com>
Date: Tue, 5 Nov 2013 15:14:00 +0100
> + if (req_len > QETH_BUFSIZE - IPA_PDU_HEADER_SIZE
> + - sizeof(struct qeth_ipacmd_hdr)
> + - sizeof(struct qeth_ipacmd_setadpparms_hdr))
> + return -EINVAL;
Please fix the indentation and parenthesize the more complicated right
side of the expression, it should be something like:
if (req_len > (QETH_BUFSIZE - IPA_PDU_HEADER_SIZE -
sizeof(struct qeth_ipacmd_hdr) -
sizeof(struct qeth_ipacmd_setadpparms_hdr)))
Thanks.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists