From: Aurelien Jarno <aurelien@aurel32.net>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [6480] linux-user: don't crash with null name
Date: Fri, 30 Jan 2009 19:48:07 +0000 [thread overview]
Message-ID: <E1LSzLT-0003UD-I0@cvs.savannah.gnu.org> (raw)
Revision: 6480
http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=6480
Author: aurel32
Date: 2009-01-30 19:48:07 +0000 (Fri, 30 Jan 2009)
Log Message:
-----------
linux-user: don't crash with null name
>From Thayne Harbaugh.
path() may be called with null string, don't bother trying to
remap in that case.
Signed-off-by: Riku Voipio <riku.voipio@iki.fi>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Modified Paths:
--------------
trunk/linux-user/path.c
Modified: trunk/linux-user/path.c
===================================================================
--- trunk/linux-user/path.c 2009-01-30 19:47:57 UTC (rev 6479)
+++ trunk/linux-user/path.c 2009-01-30 19:48:07 UTC (rev 6480)
@@ -152,7 +152,7 @@
{
/* Only do absolute paths: quick and dirty, but should mostly be OK.
Could do relative by tracking cwd. */
- if (!base || name[0] != '/')
+ if (!base || !name || name[0] != '/')
return name;
return follow_path(base, name) ?: name;
reply other threads:[~2009-01-30 19:48 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=E1LSzLT-0003UD-I0@cvs.savannah.gnu.org \
--to=aurelien@aurel32.net \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).