From owner-svn-src-head@freebsd.org Fri Jul 24 19:47:49 2015 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C39739AA0D7 for ; Fri, 24 Jul 2015 19:47:49 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from nm9-vm0.bullet.mail.bf1.yahoo.com (nm9-vm0.bullet.mail.bf1.yahoo.com [98.139.213.154]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 713881ED4 for ; Fri, 24 Jul 2015 19:47:49 +0000 (UTC) (envelope-from pfg@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1437766870; bh=BrVem3XrIqLp2Kyd/+qayNENnoHBxNr7lVln85zC39Y=; h=Date:From:To:CC:Subject:References:In-Reply-To:From:Subject; b=dyuBnwrmSM1r+ECwLo/tvZLKae95xuK5t3piflKFoCQ6htpbKtExHTPXrHsCBg0qCrQbN2hj09TG4atU5n9PFeAGnAv/xzcwZOLbSWOeD+IVbo9VKVRbZfcRZS4kOrPgfMJGr5vMYDAGrL3R4sX1JJP1FdBDOUmdc4X07jKJin/gawE6tk/ZfLIlAjKLwDDOwJKDroPZMAz7r9WJXb+47KevlgnmV4U7vBrPFi4LNMFFsaiWe1cOntZ5aI5Fig7G2bFVlDbNHa2LdxeBL3XNCF+8klaIvuT6NR6vmxN96SW7mGgm5l4DNexD6jbtPcX48obhAAr2OUjR8WgZ98opuQ== Received: from [66.196.81.172] by nm9.bullet.mail.bf1.yahoo.com with NNFMP; 24 Jul 2015 19:41:10 -0000 Received: from [98.139.213.8] by tm18.bullet.mail.bf1.yahoo.com with NNFMP; 24 Jul 2015 19:41:10 -0000 Received: from [127.0.0.1] by smtp108.mail.bf1.yahoo.com with NNFMP; 24 Jul 2015 19:41:10 -0000 X-Yahoo-Newman-Id: 689227.83104.bm@smtp108.mail.bf1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: _a7KhGwVM1lBURZZjbLQgchruUwKTda7VItV2L14.2SVNHI qSw1mqSFEc_0LB1GCD0cOGiVfr0qFU0uFisbrecllFYuynnNrh9x0Qy34sPV W8TKtR2V0Jy7DA40wPUZLnETqHZ_Ziy5mhOL3TaxyV8AEF1dYKvvVis7qwgX 19Mh2UFaBf9KdTG1M7QfpjSuy0UT0c0weny2MrOl5TCnVOcSLzIpAJYVNkY8 HrkvIDUilmiMPwFfzAnfBgGvTYblssxhrdZ4t5MfGrcTL7hgrUx2OoTz9PDR fzOCvi2xAkPJZeaMCdAesDfJ30XQXS6i85dsKqstlb8v0kSyrX8HMYG7LAUw 8BVYg2VVLoxsSl9R6wNVXd2mzQzFhEU3VCjLqhodbR_yt8SOCGCQtolySOlH ayC3KDNQVHrTq7dUnZnR7bl75vD9NN1DLbBddtao5lA5D8D4aeg61rgKZuGI 2.zCSxD7CAELurVLTKF6DasDpWrUg72eC4rbgWwEqGqw5ICZfwrbWf9qcXNq EC9XCJS2T_lVEySMIOVQRRUbaLgoCPux1 X-Yahoo-SMTP: xcjD0guswBAZaPPIbxpWwLcp9Unf Message-ID: <55B294DB.9020000@FreeBSD.org> Date: Fri, 24 Jul 2015 14:41:15 -0500 From: Pedro Giffuni User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Allan Jude , Antoine Brodin CC: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r285803 - head/bin/ls References: <201507221958.t6MJwLEk015409@repo.freebsd.org> <55B28D93.5090003@freebsd.org> In-Reply-To: <55B28D93.5090003@freebsd.org> Content-Type: multipart/mixed; boundary="------------000808070703070504020901" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Jul 2015 19:47:50 -0000 This is a multi-part message in MIME format. --------------000808070703070504020901 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit On 07/24/15 14:10, Allan Jude wrote: > ... > > The r285734 change didn't explicitly cast some references to uid_t, > resulting in a segfault on i386. Clang generated a warning about this > immediately while I was debugging when I duplicated the xo_emit > command as a printf. > > Can we teach our clang that xo_emit is printf, and so the same > formatting type matching should be checked? That would be very helpful. > Perhaps something like this? (untested) Pedro. --------------000808070703070504020901 Content-Type: text/x-patch; name="libxo-printflike.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="libxo-printflike.diff" Index: contrib/libxo/libxo/xo.h =================================================================== --- contrib/libxo/libxo/xo.h (revision 285847) +++ contrib/libxo/libxo/xo.h (working copy) @@ -160,10 +160,10 @@ xo_emit_hv (xo_handle_t *xop, const char *fmt, va_list vap); int -xo_emit_h (xo_handle_t *xop, const char *fmt, ...); +xo_emit_h (xo_handle_t *xop, const char *fmt, ...) PRINTFLIKE(2, 3) ; int -xo_emit (const char *fmt, ...); +xo_emit (const char *fmt, ...) PRINTFLIKE(1, 2); int xo_open_container_h (xo_handle_t *xop, const char *name); --------------000808070703070504020901--