Dolda2000 GitWeb
/
ashd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b9e7ec7
)
Fixed a couple of bugs in dirplex.
author
Fredrik Tolf
<fredrik@dolda2000.com>
Thu, 26 Aug 2010 23:46:55 +0000
(
01:46
+0200)
committer
Fredrik Tolf
<fredrik@dolda2000.com>
Thu, 26 Aug 2010 23:46:55 +0000
(
01:46
+0200)
src/dirplex.c
patch
|
blob
|
blame
|
history
diff --git
a/src/dirplex.c
b/src/dirplex.c
index
01d8715
..
402d654
100644
(file)
--- a/
src/dirplex.c
+++ b/
src/dirplex.c
@@
-302,6
+302,9
@@
static struct config *getconfig(char *path)
cf->mtime = mtime;
cf->lastck = now;
cf->next = cflist;
+ cf->prev = NULL;
+ if(cflist != NULL)
+ cflist->prev = cf;
cflist = cf;
return(cf);
}
@@
-445,7
+448,7
@@
static void handledir(struct hthead *req, int fd, char *path)
while((dent = readdir(dir)) != NULL) {
if((p = strchr(dent->d_name, '.')) == NULL)
continue;
- if(strncmp(dent->d_name, inm,
p - dent->d_name
))
+ if(strncmp(dent->d_name, inm,
strlen(inm)
))
continue;
ipath = sprintf2("%s/%s", path, dent->d_name);
if(stat(ipath, &sb) || !S_ISREG(sb.st_mode)) {