From owner-freebsd-hackers@FreeBSD.ORG Sun Feb 10 09:28:06 2013 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 51C95306; Sun, 10 Feb 2013 09:28:06 +0000 (UTC) (envelope-from hiren.panchasara@gmail.com) Received: from mail-ee0-f53.google.com (mail-ee0-f53.google.com [74.125.83.53]) by mx1.freebsd.org (Postfix) with ESMTP id B976512A; Sun, 10 Feb 2013 09:28:05 +0000 (UTC) Received: by mail-ee0-f53.google.com with SMTP id e53so2650930eek.26 for ; Sun, 10 Feb 2013 01:27:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=TRTe57wobQ4GdoOR5F5CLck/NPDkBorh3GkqtdBF688=; b=PtrpGc90pzINcvALBGTL1tpJKBodjNml/lVituAgimPCg4Emy+BAJzLgSoavt7R5id Dp6SgVuOvgFaA2H3N9p5XFT2CwGVKnRlcvCuvfKeXASL1JRU0l+1fp/O1Jx0CzNGoMII 6kii0m4yi7tmYzWOttks5tNMV9poOfUtFuWZo8H3tj4Q51eSBQkLvWqa9ARfYINc5aFQ CYI/AHn7GmN2zfgm+Bx1qJ5BKuC54WN4kWxjwZB/2UaIdKVlylJgIlWHMeU60MJV3HRl x1AekEg8EfFb6Ue9R9McQl0gIpTzxl/ruSnSgyaI4Bdf4y8uKIylaDt1kXxaRt9Lcm82 g3Bg== MIME-Version: 1.0 X-Received: by 10.14.2.5 with SMTP id 5mr36345886eee.30.1360488479038; Sun, 10 Feb 2013 01:27:59 -0800 (PST) Received: by 10.14.133.204 with HTTP; Sun, 10 Feb 2013 01:27:58 -0800 (PST) In-Reply-To: <1360455011.4618.8.camel@powernoodle> References: <1360455011.4618.8.camel@powernoodle> Date: Sun, 10 Feb 2013 01:27:58 -0800 Message-ID: Subject: Re: Eliminating a warning in sys/boot From: hiren panchasara To: sbruno@freebsd.org Content-Type: text/plain; charset=UTF-8 Cc: "freebsd-hackers@freebsd.org" X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Feb 2013 09:28:06 -0000 On Sat, Feb 9, 2013 at 4:10 PM, Sean Bruno wrote: > So, this is not a valid warning in our universe and I'd like to silence > it when compiling sys/boot as printf(9) and sprintf(9) supports this > format. How can we silence this warning for the FreeBSD universe? > > ===> efi/libefi (all) > In file included from efinet.c:39: > /home/sbruno/fbsd_head/sys/boot/efi/libefi/../../common/dev_net.c:328:19: warning: invalid conversion specifier 'D' > [-Wformat-invalid-specifier] > sprintf(temp, "%6D", d->myea, ":"); Here "d->myea" being char pointer, can we not do following instead? : sprintf(temp, "%6s", d->myea, ":"); Hiren