src/server/webdav/webdav.c

branch
webdav
changeset 236
e81d3e517b57
parent 235
4990147c58d0
child 237
ee1680ef1ef2
equal deleted inserted replaced
235:4990147c58d0 236:e81d3e517b57
256 } 256 }
257 257
258 int ret = REQ_PROCEED; 258 int ret = REQ_PROCEED;
259 259
260 // create WebdavResource object for requested resource 260 // create WebdavResource object for requested resource
261 if(!webdav_op_propfind_begin(op, path, NULL, statptr)) { 261 if(!webdav_op_propfind_begin(op, uri, NULL, statptr)) {
262 // propfind for the requested resource was successful 262 // propfind for the requested resource was successful
263 263
264 // usevfsdir is TRUE if 264 // usevfsdir is TRUE if
265 // the webdav backend has not disabled vfs usage 265 // the webdav backend has not disabled vfs usage
266 // the file is a directory 266 // the file is a directory
426 WebdavResource *resource, 426 WebdavResource *resource,
427 struct stat *s) 427 struct stat *s)
428 { 428 {
429 DefaultWebdavData *data = request->userdata; 429 DefaultWebdavData *data = request->userdata;
430 430
431 // TODO: rework
432
433 // add all requested vfs properties like getcontentlength ... 431 // add all requested vfs properties like getcontentlength ...
434 if(webdav_add_vfs_properties( 432 if(webdav_add_vfs_properties(
435 resource, 433 resource,
436 request->sn->pool, 434 request->sn->pool,
437 data->vfsproperties, 435 data->vfsproperties,
438 s)) 436 s))
439 { 437 {
440 return 1; 438 return 1;
441 }
442
443 // all remaining properties are not available
444 WebdavPList *p = request->properties;
445 while(p) {
446 resource->addproperty(resource, p->property, 404);
447 p = p->next;
448 } 439 }
449 440
450 return 0; 441 return 0;
451 } 442 }
452 443

mercurial