rse 98/03/27 09:37:43
Modified: . STATUS
src CHANGES
src/modules/standard mod_rewrite.c
Log:
Fix ``RewriteCond ... -l''.
Submitted by: Rein Tollevik <[EMAIL PROTECTED]>
Reviewed by: Ralf S. Engelschall
PR: 2010
Revision Changes Path
1.227 +1 -0 apache-1.3/STATUS
Index: STATUS
===================================================================
RCS file: /export/home/cvs/apache-1.3/STATUS,v
retrieving revision 1.226
retrieving revision 1.227
diff -u -r1.226 -r1.227
--- STATUS 1998/03/27 16:30:33 1.226
+++ STATUS 1998/03/27 17:37:26 1.227
@@ -116,6 +116,7 @@
* Dean's mark of a few bitfields as signed to ensure correct code.
* Dean's changes to scoreboard defs which helps gcc generate better code.
* Ralf's fix for QUERY_STRING and the proxy pass-through of mod_rewrite
+ * Fix for symlink check in mod_rewrite's ``RewriteCond ... -l'', PR#2010
Available Patches:
1.739 +4 -0 apache-1.3/src/CHANGES
Index: CHANGES
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/CHANGES,v
retrieving revision 1.738
retrieving revision 1.739
diff -u -r1.738 -r1.739
--- CHANGES 1998/03/27 15:43:49 1.738
+++ CHANGES 1998/03/27 17:37:31 1.739
@@ -1,5 +1,9 @@
Changes with Apache 1.3b6
+ *) Fix the check for symbolic links in ``RewriteCond ... -l'': stat() was
+ used instead of lstat() and thus this flag didn't work as expected.
+ [Rein Tollevik <[EMAIL PROTECTED]>, PR#2010]
+
*) Fix the proxy pass-through feature of mod_rewrite for the case of
existing QUERY_STRING now that mod_proxy was recently changed because of
the new URL parsing stuff. [Ralf S. Engelschall]
1.96 +1 -2 apache-1.3/src/modules/standard/mod_rewrite.c
Index: mod_rewrite.c
===================================================================
RCS file: /export/home/cvs/apache-1.3/src/modules/standard/mod_rewrite.c,v
retrieving revision 1.95
retrieving revision 1.96
diff -u -r1.95 -r1.96
--- mod_rewrite.c 1998/03/27 15:50:16 1.95
+++ mod_rewrite.c 1998/03/27 17:37:38 1.96
@@ -2009,8 +2009,7 @@
}
else if (strcmp(p->pattern, "-l") == 0) {
#if !defined(__EMX__) && !defined(WIN32)
-/* OS/2 dosen't support links. */
- if (stat(input, &sb) == 0)
+ if (lstat(input, &sb) == 0)
if (S_ISLNK(sb.st_mode))
rc = 1;
#endif