From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932081AbdBURug (ORCPT ); Tue, 21 Feb 2017 12:50:36 -0500 Received: from smtp.lesbg.com ([178.62.242.175]:40842 "EHLO smtp.lesbg.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754287AbdBURua (ORCPT ); Tue, 21 Feb 2017 12:50:30 -0500 Message-ID: <1487699421.13719.2.camel@lesbg.com> Subject: Re: [PATCH 1/2] Fix format overflows From: Jonathan Dieter To: Krzysztof Opasiak , linux-kernel@vger.kernel.org Cc: Valentina Manea , Shuah Khan , Peter Senna Tschudin , Greg Kroah-Hartman , "open list:USB OVER IP DRIVER" Date: Tue, 21 Feb 2017 19:50:21 +0200 In-Reply-To: <1487659710.2096.1.camel@lesbg.com> References: <20170220205129.18194-1-jdieter@lesbg.com> <1487659710.2096.1.camel@lesbg.com> Organization: Lebanon Evangelical School for Boys and Girls Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.22.5 (3.22.5-1.fc25) Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2017-02-21 at 08:48 +0200, Jonathan Dieter wrote: > On Tue, 2017-02-21 at 07:12 +0100, Krzysztof Opasiak wrote: > > Hi, > >   > > W dniu 2017-02-20 o 21:51, Jonathan Dieter pisze:  > > > + err("busid length %i >= SYSFS_BUS_ID_SIZE", > > > size); > > Should I also change the error messages to use real values? > Ex: > err("busid length %i >= %i", size, sizeof(busid)); On further reflection, I do think changing the error messages to use sizeof() is cleaner. If you disagree, please let me know. I don't have a strong feeling about it one way or the other. The next revision uses sizeof() in the places you indicated and changes size to an unsigned int since we're now comparing it to the result of sizeof(). Thanks again, Jonathan