qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] linux-user: improve fake /proc/self/stat making


From: Alexander Graf
Subject: Re: [Qemu-devel] [PATCH] linux-user: improve fake /proc/self/stat making `ps` not segfault.
Date: Tue, 3 Jan 2012 20:01:58 +0100

On 03.01.2012, at 19:54, Fabio Erculiani wrote:

> Yeah, debugging.
> 
> Moreover we have this scenario:
> 
> $ /bin/cat /proc/self/stat
> 32297 (cat) ......
> 
> I guess we should use basename() anyway...?

argv[0] can be an arbitrary value passed in through execve. In qemu's 
linux-user emulation you can even override it manually with the -argv0 command 
line option. So no, it shouldn't be basename of the file name.


Alex




reply via email to

[Prev in Thread] Current Thread [Next in Thread]