From owner-svn-src-head@FreeBSD.ORG Tue Oct 26 17:58:07 2010 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2212D106564A; Tue, 26 Oct 2010 17:58:07 +0000 (UTC) (envelope-from asmrookie@gmail.com) Received: from mail-qy0-f182.google.com (mail-qy0-f182.google.com [209.85.216.182]) by mx1.freebsd.org (Postfix) with ESMTP id 9011B8FC0A; Tue, 26 Oct 2010 17:58:06 +0000 (UTC) Received: by qyk33 with SMTP id 33so2797165qyk.13 for ; Tue, 26 Oct 2010 10:58:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=YcnGvv6YRJgAl+dODvviAsrPSLFXLJaW8Lpry+awcDA=; b=re51LzvTuUMFt4vRMd0inieDIc5fFuf6cMyxDh51KwA4ZmLwAR8x6UQJ7x2PgMXOzF 2YWaT7rmLks5vLK2KoO/r78YozrqthoqP9WsG4tNj7n3S3p25EHYOkbJe3mFiY5w/MEM n+hExtfvErnlMGmhsOlUIGur8BCyyHUcwpbFs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=L6FGQ9EZNWyD+jfJIdI5AcP83qq6HtIgctCcgmpEOtn+X310eL/Xn5P9Bcuw8hNFct fmfIccxAYICkW5XPWBtBh2d30ubI8awxlBb200t423XZdkGCctPW22f+uDFKw5Eh7wI8 maIqtlRc2MDQOHNg/NWSaIh25SsBv0u/+BiHE= MIME-Version: 1.0 Received: by 10.224.120.141 with SMTP id d13mr1665622qar.375.1288115885776; Tue, 26 Oct 2010 10:58:05 -0700 (PDT) Sender: asmrookie@gmail.com Received: by 10.229.237.9 with HTTP; Tue, 26 Oct 2010 10:58:05 -0700 (PDT) In-Reply-To: <4CC70BF9.30004@FreeBSD.org> References: <201010261616.o9QGGFgX053089@svn.freebsd.org> <4CC70BF9.30004@FreeBSD.org> Date: Tue, 26 Oct 2010 19:58:05 +0200 X-Google-Sender-Auth: -HAdEaOHB50iOr2VJ2xQeGzXopc Message-ID: From: Attilio Rao To: Dimitry Andric Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r214380 - head/sys/x86/x86 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 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: Tue, 26 Oct 2010 17:58:07 -0000 2010/10/26 Dimitry Andric : > On 2010-10-26 18:16, Attilio Rao wrote: >> >> =C2=A0 Remove usage of PRI* macro for style compliancy. > > ... >> >> - =C2=A0 =C2=A0 =C2=A0 printf(" =C2=A0chunk %d: %"PRIu64"MB (%"PRIu64" p= ages)", seqnr, >> PG2MB(pgs), >> - =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 pgs); >> + =C2=A0 =C2=A0 =C2=A0 printf(" =C2=A0chunk %d: %jdMB (%jd pages)", seqn= r, >> (uintmax_t)PG2MB(pgs), >> + =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (uintmax_t)pgs); > > If you cast to uintmax_t, you should use %ju instead. :) =C2=A0Otherwise, > cast to intmax_t, e.g. if the PG2MB macro results in a signed value. This bug was already existing with the old version, but yes, you and Bruce are obviously right. Thanks, Attilio --=20 Peace can only be achieved by understanding - A. Einstein