]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
Make http_request.c changes a bit more portable.
authorRandy Terbush <randy@apache.org>
Sun, 12 Jan 1997 02:05:42 +0000 (02:05 +0000)
committerRandy Terbush <randy@apache.org>
Sun, 12 Jan 1997 02:05:42 +0000 (02:05 +0000)
Change Copyright dates for both files.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3@77422 13f79535-47bb-0310-9956-ffa450edef68

RELEASE_1_1_X/src/main/http_request.c
RELEASE_1_1_X/src/mod_cookies.c

index a66eb2b506f9057a10d9966c1a1fd2f91b1574f5..a5426de71bbac37a82b58e4a5891e51fc83ae99f 100644 (file)
@@ -1,6 +1,6 @@
 
 /* ====================================================================
- * Copyright (c) 1995 The Apache Group.  All rights reserved.
+ * Copyright (c) 1995-1997 The Apache Group.  All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -179,7 +179,14 @@ int get_path_info(request_rec *r)
            *cp = '\0';
            return OK;
        }
+#if defined(ENOENT)
        else if (errno == ENOENT) {
+#else
+  #error Your system apparently does not define ENOENT.
+  #error Removal of these lines opens a security hole if protecting
+  #error from directory indexes with DirectoryIndex.
+       else {
+#endif
            last_cp = cp;
        
            while (--cp > path && *cp != '/')
@@ -188,10 +195,12 @@ int get_path_info(request_rec *r)
            while (cp > path && cp[-1] == '/')
                --cp;
        } 
+#if defined(ENOENT)
        else {
            log_reason("unable to determine if index file exists (stat() returned unexpected error)", r->filename, r);
-           return HTTP_FORBIDDEN;
+           return FORBIDDEN;
        }
+#endif
     }
 
     return OK;
index b94a172d6c44180fa729ee29b5728c9593bda510..836120599088402ac352cb0b5dc8e0407d796917 100644 (file)
@@ -1,6 +1,6 @@
 
 /* ====================================================================
- * Copyright (c) 1995, 1996 The Apache Group.  All rights reserved.
+ * Copyright (c) 1995-1997 The Apache Group.  All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions