Fix file times

This commit is contained in:
wbaumann 2014-06-08 19:18:58 +00:00
parent 8518b7146d
commit f4ac4f739a
2 changed files with 8 additions and 4 deletions

View File

@ -1,6 +1,10 @@
ChangeLog for davfs2 ChangeLog for davfs2
-------------------- --------------------


2014-06-08 Werner Baumann (werner.baumann@onlinehome.de)
* cache.c, add_node, update_directory:
Fix file times if LastModified is missing.

2014-05-24 Werner Baumann (werner.baumann@onlinehome.de) 2014-05-24 Werner Baumann (werner.baumann@onlinehome.de)
* webdav.c, prop_result: * webdav.c, prop_result:
Case insensitive test of path (sr #108566). Case insensitive test of path (sr #108566).

View File

@ -1552,9 +1552,6 @@ add_node(dav_node *parent, dav_props *props)
if (grpid && parent->gid != 0) if (grpid && parent->gid != 0)
node->gid = parent->gid; node->gid = parent->gid;


parent->mtime = node->mtime;
parent->ctime = node->mtime;

node->path = props->path; node->path = props->path;
node->name = props->name; node->name = props->name;
node->etag = props->etag; node->etag = props->etag;
@ -2156,7 +2153,10 @@ update_directory(dav_node *dir, time_t refresh)
add_node(dir, props); add_node(dir, props);
changed = 1; changed = 1;
} else { } else {
dir->mtime = props->mtime; if (props->mtime > dir->smtime) {
dir->smtime = props->mtime;
dir->mtime = props->mtime;
}
if (dir->mtime > dir->ctime) if (dir->mtime > dir->ctime)
dir->ctime = dir->mtime; dir->ctime = dir->mtime;
if (dir->etag) if (dir->etag)