Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756076AbaGSW7e (ORCPT ); Sat, 19 Jul 2014 18:59:34 -0400 Received: from mail-pa0-f46.google.com ([209.85.220.46]:52640 "EHLO mail-pa0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751876AbaGSW7c (ORCPT ); Sat, 19 Jul 2014 18:59:32 -0400 MIME-Version: 1.0 In-Reply-To: References: <1405697638-23767-1-git-send-email-andrey.krieger.utkin@gmail.com> Date: Sun, 20 Jul 2014 01:59:31 +0300 Message-ID: Subject: Re: [PATCH 3/5] net/netfilter/ipvs/ip_vs_ctl.c: drop argument range check just before the check for equality From: Andrey Utkin To: Julian Anastasov Cc: "linux-kernel@vger.kernel.org" , kernel-janitors@vger.kernel.org, coreteam@netfilter.org, netfilter-devel@vger.kernel.org, lvs-devel@vger.kernel.org, netdev@vger.kernel.org, dcb314@hotmail.com, David Miller , kadlec@blackhole.kfki.hu, Patrick McHardy , pablo@netfilter.org, Simon Horman , wensong@linux-vs.org Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 2014-07-19 0:06 GMT+03:00 Andrey Utkin : > What about static check at compilation time? > > #if (DAEMON_ARG_LEN > MAX_ARG_LEN) \ > || (SERVICE_ARG_LEN > MAX_ARG_LEN) \ > || (SVCDEST_ARG_LEN > MAX_ARG_LEN) > #error MAX_ARG_LEN exceeded in set_arglen table > #endif This approach doesn't work, looks because sizeof() values are not calculated at preprocessing stage. -- Andrey Utkin -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/