From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:49122) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ULhtz-000114-8Y for qemu-devel@nongnu.org; Fri, 29 Mar 2013 18:36:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ULhtx-0007zW-81 for qemu-devel@nongnu.org; Fri, 29 Mar 2013 18:36:03 -0400 Received: from terminus.zytor.com ([2001:1868:205::10]:42553 helo=mail.zytor.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ULhtw-0007uc-Ur for qemu-devel@nongnu.org; Fri, 29 Mar 2013 18:36:01 -0400 Message-ID: <5156173C.40609@zytor.com> Date: Fri, 29 Mar 2013 15:35:40 -0700 From: "H. Peter Anvin" MIME-Version: 1.0 References: <5155B0D5.5080007@redhat.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [Patch] fix /proc/self/maps output List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Christophe Lyon Cc: Peter Maydell , qemu-devel@nongnu.org On 03/29/2013 09:01 AM, Christophe Lyon wrote: > Add a space at end of line when there is no filename to print, to > conform to linux kernel format. > > Signed-off-by: Christophe Lyon > --- > linux-user/syscall.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/linux-user/syscall.c b/linux-user/syscall.c > index a148d9f..3b0ca86 100644 > --- a/linux-user/syscall.c > +++ b/linux-user/syscall.c > @@ -5016,7 +5016,7 @@ static int open_self_maps(void *cpu_env, int fd) > " %c%c%c%c %08" PRIx64 " %02x:%02x %d%s%s\n", > h2g(min), h2g(max), flag_r, flag_w, > flag_x, flag_p, offset, dev_maj, dev_min, inode, > - path[0] ? " " : "", path); > + path[0] ? " " : " ", path); > } > } > Please move the fixed space into the format. Perhaps even use a %-123s type format even... -hpa