projects
/
project
/
uhttpd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix index file handling
[project/uhttpd.git]
/
file.c
diff --git
a/file.c
b/file.c
index
8ccb06b
..
679755d
100644
(file)
--- a/
file.c
+++ b/
file.c
@@
-233,8
+233,10
@@
uh_path_lookup(struct client *cl, const char *url)
continue;
strcpy(pathptr, idx->name);
continue;
strcpy(pathptr, idx->name);
- if (!stat(path_phys, &s) && (s.st_mode & S_IFREG))
+ if (!stat(path_phys, &s) && (s.st_mode & S_IFREG)) {
+ memcpy(&p.stat, &s, sizeof(p.stat));
break;
break;
+ }
*pathptr = 0;
}
*pathptr = 0;
}
@@
-246,10
+248,6
@@
uh_path_lookup(struct client *cl, const char *url)
return p.phys ? &p : NULL;
}
return p.phys ? &p : NULL;
}
-#ifdef __APPLE__
-time_t timegm (struct tm *tm);
-#endif
-
static const char * uh_file_mime_lookup(const char *path)
{
struct mimetype *m = &uh_mime_types[0];
static const char * uh_file_mime_lookup(const char *path)
{
struct mimetype *m = &uh_mime_types[0];