From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCH net-next] net: sctp: sctp_auth_make_key_vector: remove duplicate ntohs calls Date: Thu, 07 Feb 2013 23:45:20 -0500 (EST) Message-ID: <20130207.234520.1493484945207262693.davem@davemloft.net> References: Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: vyasevich@gmail.com, linux-sctp@vger.kernel.org, netdev@vger.kernel.org To: dborkman@redhat.com Return-path: Received: from shards.monkeyblade.net ([149.20.54.216]:56767 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759902Ab3BHEpW (ORCPT ); Thu, 7 Feb 2013 23:45:22 -0500 In-Reply-To: Sender: netdev-owner@vger.kernel.org List-ID: From: Daniel Borkmann Date: Thu, 7 Feb 2013 12:41:39 +0100 > Instead of calling 3 times ntohs(random->param_hdr.length), 2 times > ntohs(hmacs->param_hdr.length), and 3 times ntohs(chunks->param_hdr.length) > within the same function, we only call each once and store it in a > variable. > > Signed-off-by: Daniel Borkmann Applied.