2004-04-30 Roland McGrath <roland@frob.com>

* hurd/hurdlookup.c (__hurd_file_name_split): Return ENOENT for "".
	(__hurd_directory_name_split): Likewise.
This commit is contained in:
Roland McGrath 2004-05-10 20:11:11 +00:00
parent dcf147a539
commit 92d6708bf8

View File

@ -1,4 +1,5 @@
/* Copyright (C) 1992,93,94,95,96,97,99,2001 Free Software Foundation, Inc. /* Copyright (C) 1992,93,94,95,96,97,99,2001,2004
Free Software Foundation, Inc.
This file is part of the GNU C Library. This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or The GNU C Library is free software; you can redistribute it and/or
@ -141,6 +142,8 @@ __hurd_file_name_split (error_t (*use_init_port)
dirname, 0, 0, dir); dirname, 0, 0, dir);
} }
} }
else if (file_name[0] == '\0')
return ENOENT;
else else
{ {
/* "foobar" => cwdir + "foobar". */ /* "foobar" => cwdir + "foobar". */
@ -216,6 +219,8 @@ __hurd_directory_name_split (error_t (*use_init_port)
dirname, 0, 0, dir); dirname, 0, 0, dir);
} }
} }
else if (file_name[0] == '\0')
return ENOENT;
else else
{ {
/* "foobar" => cwdir + "foobar". */ /* "foobar" => cwdir + "foobar". */