GNOME Bugzilla – Bug 566330
WebDAV backend for addressbook is too strict about content-type.
Last modified: 2011-06-22 08:48:19 UTC
Please describe the problem: WebDAV backend for addressbook is too strict about content-type. This prevents simple WebDAV stores (without special configuration) from work. E.g. my sample webdav server returned "text/plain; charset=UTF-8" as the content-type for the vcards saved on the server, while the code was checking strictly for "text/x-vcard". I suggest to disable the checking completely for now (or implement more clever content-type checking, that would allow at least for following content-types: "text/plain", "text/x-vcard", "text/vcard", "text/directory", "text/directory;profile=vCard" and that would handle properly the charset option). The backend parses (and thus checks) the content of the resource anyway, so checking for content-type doesn't really bring anything... Steps to reproduce: Actual results: Expected results: Does this happen every time? Other information:
Created attachment 125649 [details] [review] Patch which comments out content-type checks for the GET request With this patch a simple webdav store (on apache without special configuration) starts to work...
I dont think this is a nice idea, but lets check with matze, who is the author of the the backend.
I had some reports from other people with similar problems and indeed most mime-type files delivered with linux distros seem to lack entries for vcard files. I agree that the current Content-Type parser in the code is too naiv. Making the pragmatic choice of disabling it is the best thing to do at the moment :-(
Created commit c771dfd in eds master (2.31.2+) Created commit 2870c01 in eds gnome-2-30 (2.30.2+) Pity it took so long.
One problem with that, it tries to create a contact for regular text/html responses, which makes contact empty. I changed this within commit for bug #617168 in master and in: Created commit c840dac in eds gnome-2-30 (2.30.2+)
*** Bug 610572 has been marked as a duplicate of this bug. ***