Changeset 2093
- Timestamp:
- 02/26/2008 04:22:08 PM (3 months ago)
- Files:
-
- branches/lighttpd-1.4.x/src/response.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/lighttpd-1.4.x/src/response.c
r2080 r2093 554 554 555 555 do { 556 struct stat st;557 558 556 if (slash) { 559 557 buffer_copy_string_len(con->physical.path, srv->tmp_buf->ptr, slash - srv->tmp_buf->ptr); … … 562 560 } 563 561 564 if (0 == stat(con->physical.path->ptr, &(st)) && 565 S_ISREG(st.st_mode)) { 566 found = 1; 562 if (HANDLER_ERROR != stat_cache_get_entry(srv, con, con->physical.path, &sce)) { 563 found = S_ISREG(sce->st.st_mode); 567 564 break; 568 565 } … … 595 592 return HANDLER_FINISHED; 596 593 } 594 595 #ifdef HAVE_LSTAT 596 if ((sce->is_symlink != 0) && !con->conf.follow_symlink) { 597 con->http_status = 403; 598 599 if (con->conf.log_request_handling) { 600 log_error_write(srv, __FILE__, __LINE__, "s", "-- access denied due symlink restriction"); 601 log_error_write(srv, __FILE__, __LINE__, "sb", "Path :", con->physical.path); 602 } 603 604 buffer_reset(con->physical.path); 605 return HANDLER_FINISHED; 606 }; 607 #endif 597 608 598 609 /* we have a PATHINFO */

