diff -r 0edfb4c0e7f8 -r 7b1ca53f3897 dav/main.c --- a/dav/main.c Thu Aug 03 12:31:17 2017 +0200 +++ b/dav/main.c Thu Aug 03 12:48:28 2017 +0200 @@ -790,9 +790,6 @@ int put_entry(Repository *repo, CmdArgs *a, DavSession *sn, char *path, char *file, DavBool root) { int recursive = cmd_getoption(a, "recursive") ? 1 : 0; - if(recursive && !root) { - printf("put: %s\n", file); - } struct stat s; if(stat(file, &s)) { perror("stat"); @@ -809,6 +806,11 @@ file); return 1; } + + if(!root) { + printf("mkcol: %s\n", file); + } + DIR *dir = opendir(file); if(!dir) { // error @@ -846,6 +848,10 @@ dav_resource_free(res); } } else if(S_ISREG(s.st_mode)) { + if(recursive) { + printf("put: %s\n", file); + } + /* * use stdin if the input file is - */