* errno.cc (errmap): Map ERROR_BAD_NETPATH to new errno ENOSHARE.
(_sys_errlist): Add entry for ENOSHARE. (strerror): Add case for ENOSHARE. * syscalls.cc (stat_worker): Check for errno ENOSHARE.
This commit is contained in:
parent
b96fca8c5a
commit
07a135a6bf
|
@ -1,3 +1,10 @@
|
|||
Wed May 3 18:07:00 2000 Corinna Vinschen <corinna@vinschen.de>
|
||||
|
||||
* errno.cc (errmap): Map ERROR_BAD_NETPATH to new errno ENOSHARE.
|
||||
(_sys_errlist): Add entry for ENOSHARE.
|
||||
(strerror): Add case for ENOSHARE.
|
||||
* syscalls.cc (stat_worker): Check for errno ENOSHARE.
|
||||
|
||||
Wed May 3 17:28:00 2000 Corinna Vinschen <corinna@vinschen.de>
|
||||
|
||||
* Makefile.in: Add dependencies for fhandler_random.o
|
||||
|
|
|
@ -50,7 +50,7 @@ errmap[] =
|
|||
X (NOT_SUPPORTED, ENOSYS),
|
||||
X (REM_NOT_LIST, ENONET),
|
||||
X (DUP_NAME, ENOTUNIQ),
|
||||
X (BAD_NETPATH, ENXIO),
|
||||
X (BAD_NETPATH, ENOSHARE),
|
||||
X (FILE_EXISTS, EEXIST),
|
||||
X (CANNOT_MAKE, EPERM),
|
||||
X (INVALID_PARAMETER, EINVAL),
|
||||
|
@ -279,7 +279,8 @@ extern const char __declspec(dllexport) * const _sys_errlist[]=
|
|||
/* EDQUOT 132 */ "Quota exceeded",
|
||||
/* ESTALE 133 */ "Stale NFS file handle",
|
||||
/* ENOTSUP 134 */ "134",
|
||||
/* ENOMEDIUM 135 */ "no medium"
|
||||
/* ENOMEDIUM 135 */ "no medium",
|
||||
/* ENOSHARE 136 */ "No such host or network path"
|
||||
};
|
||||
|
||||
int __declspec(dllexport) _sys_nerr =
|
||||
|
@ -652,6 +653,9 @@ strerror (int errnum)
|
|||
case ENOMEDIUM:
|
||||
error = "no medium";
|
||||
break;
|
||||
case ENOSHARE:
|
||||
error = "No such host or network path";
|
||||
break;
|
||||
default:
|
||||
#ifdef _MT_SAFE
|
||||
char *buf= _reent_winsup()->_strerror_buf;
|
||||
|
|
|
@ -1030,7 +1030,8 @@ stat_worker (const char *caller, const char *name, struct stat *buf,
|
|||
buf->st_nlink =
|
||||
(dtype == DRIVE_REMOTE ? 1 : num_entries (real_path.get_win32 ()));
|
||||
}
|
||||
else if (atts != -1 || (!oret && get_errno () != ENOENT))
|
||||
else if (atts != -1 || (!oret && get_errno () != ENOENT
|
||||
&& get_errno () != ENOSHARE))
|
||||
{
|
||||
/* Unfortunately, the above open may fail if the file exists, though.
|
||||
So we have to care for this case here, too. */
|
||||
|
|
Loading…
Reference in New Issue