[evolution-data-server] [EWebDAVDiscover] Correct href sets reading
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server] [EWebDAVDiscover] Correct href sets reading
- Date: Tue, 1 Aug 2017 10:57:55 +0000 (UTC)
commit 02ddc45ca885fb080e10be12ff697d8c69110783
Author: Milan Crha <mcrha redhat com>
Date: Tue Aug 1 12:55:56 2017 +0200
[EWebDAVDiscover] Correct href sets reading
Only the first href in the set had been read, due to incorrect XPath
being used to get the count of the href-s returned from the server.
Also fixed one unrelated typo in a code comment.
src/libedataserver/e-webdav-discover.c | 6 +++---
src/libedataserver/e-webdav-session.h | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/libedataserver/e-webdav-discover.c b/src/libedataserver/e-webdav-discover.c
index 8621a5e..d2ff7b3 100644
--- a/src/libedataserver/e-webdav-discover.c
+++ b/src/libedataserver/e-webdav-discover.c
@@ -102,7 +102,7 @@ e_webdav_discover_traverse_propfind_response_cb (EWebDAVSession *webdav,
xmlXPathObjectPtr xpath_obj;
gchar *principal_href, *full_href;
- xpath_obj = e_xml_xpath_eval (xpath_ctx, "%s/A:addressbook-home-set", xpath_prop_prefix);
+ xpath_obj = e_xml_xpath_eval (xpath_ctx, "%s/A:addressbook-home-set/D:href",
xpath_prop_prefix);
if (xpath_obj) {
gint ii, length;
@@ -137,7 +137,7 @@ e_webdav_discover_traverse_propfind_response_cb (EWebDAVSession *webdav,
xmlXPathFreeObject (xpath_obj);
}
- xpath_obj = e_xml_xpath_eval (xpath_ctx, "%s/C:calendar-home-set", xpath_prop_prefix);
+ xpath_obj = e_xml_xpath_eval (xpath_ctx, "%s/C:calendar-home-set/D:href", xpath_prop_prefix);
if (xpath_obj) {
gint ii, length;
@@ -170,7 +170,7 @@ e_webdav_discover_traverse_propfind_response_cb (EWebDAVSession *webdav,
xmlXPathFreeObject (xpath_obj);
}
- xpath_obj = e_xml_xpath_eval (xpath_ctx, "%s/C:calendar-user-address-set", xpath_prop_prefix);
+ xpath_obj = e_xml_xpath_eval (xpath_ctx, "%s/C:calendar-user-address-set/D:href",
xpath_prop_prefix);
if (xpath_obj) {
gint ii, length;
diff --git a/src/libedataserver/e-webdav-session.h b/src/libedataserver/e-webdav-session.h
index c20aa36..0c7eb54 100644
--- a/src/libedataserver/e-webdav-session.h
+++ b/src/libedataserver/e-webdav-session.h
@@ -281,7 +281,7 @@ typedef enum {
typedef struct _EWebDAVAccessControlEntry {
EWebDAVACEPrincipalKind principal_kind;
- gchar *principal_href; /* valid onyl if principal_kind is E_WEBDAV_ACE_PRINCIPAL_HREF */
+ gchar *principal_href; /* valid only if principal_kind is E_WEBDAV_ACE_PRINCIPAL_HREF */
guint32 flags; /* bit-or of EWebDAVACEFlag */
gchar *inherited_href; /* valid only if flags contain E_WEBDAV_ACE_INHERITED */
GSList *privileges; /* EWebDAVPrivilege * */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]