bnicholes 01/09/14 16:19:47
Modified: file_io/win32 filepath.c
Log:
Changed the NetWare deconstruct() if statement to look for a specific error.
Revision Changes Path
1.15 +5 -3 apr/file_io/win32/filepath.c
Index: filepath.c
===================================================================
RCS file: /home/cvs/apr/file_io/win32/filepath.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- filepath.c 2001/09/10 19:08:35 1.14
+++ filepath.c 2001/09/14 23:19:47 1.15
@@ -93,13 +93,15 @@
/* Split the inpath into its separate parts. If it fails then
we know we have a bad path.
*/
- if (deconstruct(testpath, server, volume, path, file, NULL, &elements,
PATH_UNDEF))
- return APR_EBADPATH;
+ if (deconstruct(testpath, server, volume, path, file, NULL, &elements,
PATH_UNDEF)) {
+ if (errno == EINVAL)
+ return APR_EBADPATH;
+ }
/* If we got a volume part then continue splitting out the root.
Otherwise we either have an incomplete or relative path
*/
- if (strlen(volume) > 0) {
+ if (volume && strlen(volume) > 0) {
newpath = apr_pcalloc(p, strlen(server)+strlen(volume)+5);
construct(newpath, server, volume, NULL, NULL, NULL, PATH_NETWARE);