From owner-svn-src-all@freebsd.org Tue Aug 1 06:39:54 2017 Return-Path: Delivered-To: svn-src-all@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 88F58DB64EE; Tue, 1 Aug 2017 06:39:54 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citapm.icyb.net.ua (citapm.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 4FFB266B99; Tue, 1 Aug 2017 06:39:52 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citapm.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id JAA17505; Tue, 01 Aug 2017 09:39:44 +0300 (EEST) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1dcQqG-000OhV-HI; Tue, 01 Aug 2017 09:39:44 +0300 Subject: Re: svn commit: r321849 - in head/tools/tools: bootparttest zfsboottest To: Ngie Cooper , src-committers@FreeBSD.org, svn-src-all@FreeBSD.org, svn-src-head@FreeBSD.org References: <201708010529.v715Ta2p047371@repo.freebsd.org> From: Andriy Gapon Message-ID: Date: Tue, 1 Aug 2017 09:39:08 +0300 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <201708010529.v715Ta2p047371@repo.freebsd.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Aug 2017 06:39:54 -0000 On 01/08/2017 08:29, Ngie Cooper wrote: > Author: ngie > Date: Tue Aug 1 05:29:36 2017 > New Revision: 321849 > URL: https://svnweb.freebsd.org/changeset/base/321849 > > Log: > Fix the return type for pager_output(..) in bootparttest and zfsboottest > > pager_output(..) has always returned int. For some reason (probably the > clang 5.0 update), this mismatch now results in an error with CC=clang. > > MFC after: 1 week I am not sure if this a correct fix... Return value of pager_output() signifies whether to continue printing, return value of printf is a number of characters printed. > head/tools/tools/bootparttest/stub.c > head/tools/tools/zfsboottest/zfsboottest.c > > Modified: head/tools/tools/bootparttest/stub.c > ============================================================================== > --- head/tools/tools/bootparttest/stub.c Tue Aug 1 05:26:45 2017 (r321848) > +++ head/tools/tools/bootparttest/stub.c Tue Aug 1 05:29:36 2017 (r321849) > @@ -44,9 +44,9 @@ Free(void *ptr, const char *file, int line) > return (free(ptr)); > } > > -void > +int > pager_output(const char *s) > { > > - printf("%s", s); > + return (printf("%s", s)); > } > > Modified: head/tools/tools/zfsboottest/zfsboottest.c > ============================================================================== > --- head/tools/tools/zfsboottest/zfsboottest.c Tue Aug 1 05:26:45 2017 (r321848) > +++ head/tools/tools/zfsboottest/zfsboottest.c Tue Aug 1 05:29:36 2017 (r321849) > @@ -43,11 +43,11 @@ > > #define NBBY 8 > > -void > +int > pager_output(const char *line) > { > > - fprintf(stderr, "%s", line); > + return (fprintf(stderr, "%s", line)); > } > > #define ZFS_TEST > -- Andriy Gapon