From 3b12a57cb6575f24443931871ed169c54a802df5 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Fri, 24 Jun 2005 09:12:15 +0000 Subject: * fhandler.cc (rootdir): Don't set errno. * syscalls.cc (statvfs): Set errno to ENOTDIR if rootdir() failed. --- winsup/cygwin/fhandler.cc | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'winsup/cygwin/fhandler.cc') diff --git a/winsup/cygwin/fhandler.cc b/winsup/cygwin/fhandler.cc index c5074a3fe..2f034007a 100644 --- a/winsup/cygwin/fhandler.cc +++ b/winsup/cygwin/fhandler.cc @@ -1179,18 +1179,14 @@ rootdir (const char *full_path, char *root_path) { const char *cp = strchr (full_path + 2, '\\'); if (!cp) - goto error; + return NULL; while (*++cp && *cp != '\\') ; memcpy (root_path, full_path, (len = cp - full_path)); rootp = root_path + len; } else - { - error: - set_errno (ENOTDIR); - return NULL; - } + return NULL; *rootp++ = '\\'; *rootp = '\0'; -- cgit v1.2.3