Hello community,

here is the log from the commit of package evolution-ews for openSUSE:Factory 
checked in at 2015-07-14 17:45:06
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/evolution-ews (Old)
 and      /work/SRC/openSUSE:Factory/.evolution-ews.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "evolution-ews"

Changes:
--------
--- /work/SRC/openSUSE:Factory/evolution-ews/evolution-ews.changes      
2015-06-09 08:50:36.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.evolution-ews.new/evolution-ews.changes 
2015-07-14 17:46:22.000000000 +0200
@@ -1,0 +2,18 @@
+Mon Jul 13 12:10:54 UTC 2015 - [email protected]
+
+- Update to version 3.16.4:
+  + Remove unused variable.
+  + configure.ac: Do not override localedir variable.
+  + Use e_source_remove_sync() instead of
+    e_source_registry_server_remove_source().
+  + Make sure collection child sources are enabled when created.
+  + Differentiate between Unavailable and No response errors.
+  + ews_dump_raw_soup_message: Check for non-NULL hdrs and body
+    arguments.
+  + Bugs fixed: bgo#471791, bgo#751001, bgo#751547, bgo#751725.
+- Drop evolution-ews-intltool-path.patch: Fixed upstream. Also drop
+  gnome-common BuildRequires and call to gnome-autogen.sh, as we do
+  not have any patches anymore. No longer delete po/Makefile*
+  either.
+
+-------------------------------------------------------------------

Old:
----
  evolution-ews-3.16.3.tar.xz
  evolution-ews-intltool-path.patch

New:
----
  evolution-ews-3.16.4.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ evolution-ews.spec ++++++
--- /var/tmp/diff_new_pack.52MWAJ/_old  2015-07-14 17:46:23.000000000 +0200
+++ /var/tmp/diff_new_pack.52MWAJ/_new  2015-07-14 17:46:23.000000000 +0200
@@ -19,18 +19,14 @@
 Name:           evolution-ews
 # This should be updated upon major version changes; it should match 
BASE_VERSION as defined in configure.in.
 %define evolution_base_version 3.16
-Version:        3.16.3
+Version:        3.16.4
 Release:        0
 Summary:        Exchange Connector for Evolution, compatible with Exchange 
2007 and later
 License:        LGPL-2.1
 Group:          Productivity/Networking/Email/Clients
 Url:            http://projects.gnome.org/evolution/
 Source:         
http://download.gnome.org/sources/evolution-ews/3.16/%{name}-%{version}.tar.xz
-# PATCH-FIX-UPSTREAM evolution-ews-intltool-path.patch bgo#750571 
[email protected] -- Fix installation of locales when building using recent 
intltools
-Patch0:         evolution-ews-intltool-path.patch
 BuildRequires:  fdupes
-# Needed for patch0
-BuildRequires:  gnome-common
 BuildRequires:  intltool
 BuildRequires:  translation-update-upstream
 BuildRequires:  pkgconfig(enchant)
@@ -90,14 +86,9 @@
 %lang_package
 %prep
 %setup -q
-%patch0 -p1
-# let's just intltoolize this tarball
-rm po/Makefile*
 translation-update-upstream
 
 %build
-# Needed for patch0
-NOCONFIGURE=1 gnome-autogen.sh
 %{configure} \
   --disable-static
 make %{?_smp_mflags}

++++++ evolution-ews-3.16.3.tar.xz -> evolution-ews-3.16.4.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/NEWS 
new/evolution-ews-3.16.4/NEWS
--- old/evolution-ews-3.16.3/NEWS       2015-06-08 09:21:40.000000000 +0200
+++ new/evolution-ews-3.16.4/NEWS       2015-07-13 07:48:08.000000000 +0200
@@ -1,3 +1,20 @@
+Evolution-EWS 3.16.4 2015-07-13
+-------------------------------
+
+Bug Fixes:
+       Bug 471791 - Move away from g_asserts to g_ret* (Milan Crha)
+       Bug 751001 - Permissions on context menu for GAL should be disabled 
(Milan Crha)
+       Bug 751547 - Foreign calendars hidden after account enable (Milan Crha)
+       Bug 751725 - Enhance thread safety around CamelEwsStore::connection 
(Milan Crha)
+
+Miscellaneous:
+       Remove unused variable (Milan Crha)
+       configure.ac: Do not override localedir variable (Milan Crha)
+       Use e_source_remove_sync() instead of 
e_source_registry_server_remove_source() (Milan Crha)
+       Make sure collection child sources are enabled when created (Milan Crha)
+       Differentiate between Unavailable and No response errors (Milan Crha)
+       ews_dump_raw_soup_message: Check for non-NULL hdrs and body arguments 
(Milan Crha)
+
 Evolution-EWS 3.16.3 2015-06-08
 -------------------------------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/configure 
new/evolution-ews-3.16.4/configure
--- old/evolution-ews-3.16.3/configure  2015-06-08 09:22:17.000000000 +0200
+++ new/evolution-ews-3.16.4/configure  2015-07-13 07:48:53.000000000 +0200
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for evolution-ews 3.16.3.
+# Generated by GNU Autoconf 2.69 for evolution-ews 3.16.4.
 #
 # Report bugs to <http://bugzilla.gnome.org/browse.cgi?product=evolution-ews>.
 #
@@ -591,8 +591,8 @@
 # Identity of this package.
 PACKAGE_NAME='evolution-ews'
 PACKAGE_TARNAME='evolution-ews'
-PACKAGE_VERSION='3.16.3'
-PACKAGE_STRING='evolution-ews 3.16.3'
+PACKAGE_VERSION='3.16.4'
+PACKAGE_STRING='evolution-ews 3.16.4'
 PACKAGE_BUGREPORT='http://bugzilla.gnome.org/browse.cgi?product=evolution-ews'
 PACKAGE_URL=''
 
@@ -1515,7 +1515,7 @@
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures evolution-ews 3.16.3 to adapt to many kinds of systems.
+\`configure' configures evolution-ews 3.16.4 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1585,7 +1585,7 @@
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of evolution-ews 3.16.3:";;
+     short | recursive ) echo "Configuration of evolution-ews 3.16.4:";;
    esac
   cat <<\_ACEOF
 
@@ -1786,7 +1786,7 @@
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-evolution-ews configure 3.16.3
+evolution-ews configure 3.16.4
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2155,7 +2155,7 @@
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by evolution-ews $as_me 3.16.3, which was
+It was created by evolution-ews $as_me 3.16.4, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -3018,7 +3018,7 @@
 
 # Define the identity of the package.
  PACKAGE='evolution-ews'
- VERSION='3.16.3'
+ VERSION='3.16.4'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -3257,11 +3257,11 @@
 # precisely one minor behind [ews_version], then allow building against *that*
 # version of EDS and Evo.
 read x NEWSVER y < NEWS
-PREVVER=3.16.$(expr 3 - 1)
+PREVVER=3.16.$(expr 4 - 1)
 if test "$PREVVER" = "$NEWSVER"; then
    EVOREQVER=$PREVVER
 else
-   EVOREQVER=3.16.3
+   EVOREQVER=3.16.4
 fi
 
 
@@ -14212,9 +14212,6 @@
 _ACEOF
 
 
-localedir='$(prefix)/$(DATADIRNAME)/locale'
-
-
 # Check whether --enable-static was given.
 if test "${enable_static+set}" = set; then :
   enableval=$enable_static; p=${PACKAGE-default}
@@ -17426,7 +17423,7 @@
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by evolution-ews $as_me 3.16.3, which was
+This file was extended by evolution-ews $as_me 3.16.4, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -17492,7 +17489,7 @@
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; 
s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-evolution-ews config.status 3.16.3
+evolution-ews config.status 3.16.4
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/configure.ac 
new/evolution-ews-3.16.4/configure.ac
--- old/evolution-ews-3.16.3/configure.ac       2015-05-11 08:02:46.000000000 
+0200
+++ new/evolution-ews-3.16.4/configure.ac       2015-06-11 10:14:24.000000000 
+0200
@@ -1,7 +1,7 @@
 dnl Evolution-EWS version
 m4_define([ews_major_version], [3])
 m4_define([ews_minor_version], [16])
-m4_define([ews_micro_version], [3])
+m4_define([ews_micro_version], [4])
 
 m4_define([ews_version],
        [ews_major_version.ews_minor_version.ews_micro_version])
@@ -199,9 +199,6 @@
 AC_SUBST(GETTEXT_PACKAGE)
 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Package name for 
gettext])
 
-localedir='$(prefix)/$(DATADIRNAME)/locale'
-AC_SUBST(localedir)
-
 dnl ****************************
 dnl Initialize libtool
 dnl ****************************
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/evolution-ews-3.16.3/src/addressbook/ews-oab-decoder.c 
new/evolution-ews-3.16.4/src/addressbook/ews-oab-decoder.c
--- old/evolution-ews-3.16.3/src/addressbook/ews-oab-decoder.c  2015-05-22 
13:47:17.000000000 +0200
+++ new/evolution-ews-3.16.4/src/addressbook/ews-oab-decoder.c  2015-06-17 
12:13:50.000000000 +0200
@@ -791,7 +791,7 @@
                        g_slist_free ((GSList *) val);
                        break;
                default:
-                       g_assert_not_reached ();
+                       g_warn_if_reached ();
                        break;
        }
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/src/camel/camel-ews-store.c 
new/evolution-ews-3.16.4/src/camel/camel-ews-store.c
--- old/evolution-ews-3.16.3/src/camel/camel-ews-store.c        2015-04-29 
14:40:25.000000000 +0200
+++ new/evolution-ews-3.16.4/src/camel/camel-ews-store.c        2015-06-30 
22:13:07.000000000 +0200
@@ -634,11 +634,19 @@
        CamelEwsStore *ews_store = user_data;
        EEwsOofSettings *oof_settings;
        EEwsOofState oof_state;
+       EEwsConnection *cnc;
        GError *local_error = NULL;
 
+       cnc = camel_ews_store_ref_connection (ews_store);
+       if (!cnc)
+               return;
+
        camel_operation_push_message (cancellable, _("Checking \"Out of 
Office\" settings"));
 
-       oof_settings = e_ews_oof_settings_new_sync 
(ews_store->priv->connection, cancellable, &local_error);
+       oof_settings = e_ews_oof_settings_new_sync (cnc, cancellable, 
&local_error);
+
+       g_clear_object (&cnc);
+
        if (local_error != NULL) {
                g_propagate_error (error, local_error);
                camel_operation_pop_message (cancellable);
@@ -688,6 +696,7 @@
 {
        struct ScheduleUpdateData *sud = user_data;
        CamelEwsStore *ews_store = sud->ews_store;
+       EEwsConnection *cnc = NULL;
        GSList *created = NULL;
        GSList *updated = NULL;
        GSList *deleted = NULL;
@@ -698,9 +707,13 @@
        if (g_cancellable_is_cancelled (sud->cancellable))
                goto exit;
 
+       cnc = camel_ews_store_ref_connection (ews_store);
+       if (!cnc)
+               goto exit;
+
        old_sync_state = camel_ews_store_summary_get_string_val 
(ews_store->summary, "sync_state", NULL);
        if (!e_ews_connection_sync_folder_hierarchy_sync (
-                       ews_store->priv->connection,
+                       cnc,
                        EWS_PRIORITY_LOW,
                        old_sync_state,
                        &new_sync_state,
@@ -739,6 +752,7 @@
 
 exit:
        g_free (old_sync_state);
+       g_clear_object (&cnc);
        free_schedule_update_data (sud);
        return NULL;
 }
@@ -1035,8 +1049,10 @@
 {
        struct HandleNotificationsData *hnd = data;
        CamelEwsStore *ews_store = hnd->ews_store;
+       EEwsConnection *cnc;
 
-       if (ews_store->priv->connection == NULL)
+       cnc = camel_ews_store_ref_connection (ews_store);
+       if (!cnc)
                goto exit;
 
        if (ews_store->priv->listen_notifications) {
@@ -1044,7 +1060,7 @@
                        goto exit;
 
                e_ews_connection_enable_notifications_sync (
-                       ews_store->priv->connection,
+                       cnc,
                        hnd->folders,
                        &ews_store->priv->subscription_key);
        } else {
@@ -1052,7 +1068,7 @@
                        goto exit;
 
                e_ews_connection_disable_notifications_sync (
-                       ews_store->priv->connection,
+                       cnc,
                        ews_store->priv->subscription_key);
 
                ews_store->priv->subscription_key = 0;
@@ -1060,6 +1076,8 @@
 
 exit:
        handle_notifications_data_free (hnd);
+       g_clear_object (&cnc);
+
        return NULL;
 }
 
@@ -1087,13 +1105,18 @@
                                      CamelEwsSettings *ews_settings)
 {
        GThread *thread;
+       EEwsConnection *cnc;
        struct HandleNotificationsData *hnd;
 
-       if (ews_store->priv->connection == NULL)
+       cnc = camel_ews_store_ref_connection (ews_store);
+
+       if (!cnc)
                return;
 
-       if (!e_ews_connection_satisfies_server_version 
(ews_store->priv->connection, E_EWS_EXCHANGE_2010_SP1))
+       if (!e_ews_connection_satisfies_server_version (cnc, 
E_EWS_EXCHANGE_2010_SP1)) {
+               g_clear_object (&cnc);
                return;
+       }
 
        hnd = g_new0 (struct HandleNotificationsData, 1);
        hnd->ews_store = g_object_ref (ews_store);
@@ -1119,6 +1142,8 @@
                camel_folder_info_free (fi);
        }
 
+       g_clear_object (&cnc);
+
        thread = g_thread_new (NULL, start_notifications_thread, hnd);
        g_thread_unref (thread);
 }
@@ -1213,11 +1238,15 @@
                        CAMEL_OFFLINE_STORE (ews_store),
                        TRUE, cancellable, NULL);
 
-               g_signal_connect_swapped (
-                       priv->connection,
-                       "server-notification",
-                       G_CALLBACK (camel_ews_store_server_notification_cb),
-                       ews_store);
+               connection = camel_ews_store_ref_connection (ews_store);
+               if (connection) {
+                       g_signal_connect_swapped (
+                               connection,
+                               "server-notification",
+                               G_CALLBACK 
(camel_ews_store_server_notification_cb),
+                               ews_store);
+                       g_clear_object (&connection);
+               }
        }
 
        g_signal_connect_swapped (
@@ -1260,16 +1289,10 @@
        UPDATE_UNLOCK (ews_store);
 }
 
-static gboolean
-ews_disconnect_sync (CamelService *service,
-                     gboolean clean,
-                     GCancellable *cancellable,
-                     GError **error)
+static void
+ews_store_unset_connection_locked (CamelEwsStore *ews_store)
 {
-       CamelEwsStore *ews_store = CAMEL_EWS_STORE (service);
-       CamelServiceClass *service_class;
-
-       g_mutex_lock (&ews_store->priv->connection_lock);
+       g_return_if_fail (CAMEL_IS_EWS_STORE (ews_store));
 
        /* TODO cancel all operations in the connection */
        if (ews_store->priv->connection != NULL) {
@@ -1281,8 +1304,8 @@
                 *       our own reference to that CamelSettings instance, or
                 *       better yet avoid connecting signal handlers to it in
                 *       the first place. */
-               settings = camel_service_ref_settings (service);
-               g_signal_handlers_disconnect_by_data (settings, service);
+               settings = camel_service_ref_settings (CAMEL_SERVICE 
(ews_store));
+               g_signal_handlers_disconnect_by_data (settings, ews_store);
                g_signal_handlers_disconnect_by_func (
                        ews_store->priv->connection, 
camel_ews_store_server_notification_cb, ews_store);
 
@@ -1307,7 +1330,19 @@
                g_object_unref (ews_store->priv->connection);
                ews_store->priv->connection = NULL;
        }
+}
 
+static gboolean
+ews_disconnect_sync (CamelService *service,
+                     gboolean clean,
+                     GCancellable *cancellable,
+                     GError **error)
+{
+       CamelEwsStore *ews_store = CAMEL_EWS_STORE (service);
+       CamelServiceClass *service_class;
+
+       g_mutex_lock (&ews_store->priv->connection_lock);
+       ews_store_unset_connection_locked (ews_store);
        g_mutex_unlock (&ews_store->priv->connection_lock);
 
        service_class = CAMEL_SERVICE_CLASS (camel_ews_store_parent_class);
@@ -1759,6 +1794,11 @@
        g_free (old_sync_state);
        old_sync_state = NULL;
 
+       if (g_error_matches (local_error, EWS_CONNECTION_ERROR, 
EWS_CONNECTION_ERROR_UNAVAILABLE)) {
+               local_error->domain = CAMEL_SERVICE_ERROR;
+               local_error->code = CAMEL_SERVICE_ERROR_UNAVAILABLE;
+       }
+
        if (!initial_setup && g_error_matches (local_error, 
EWS_CONNECTION_ERROR, EWS_CONNECTION_ERROR_INVALIDSYNCSTATEDATA)) {
                g_clear_error (&local_error);
                ews_store_forget_all_folders (ews_store);
@@ -1776,8 +1816,7 @@
                GSList *foreign_fids, *ff;
 
                g_mutex_lock (&ews_store->priv->connection_lock);
-               if (ews_store->priv->connection != NULL)
-                       g_object_unref (ews_store->priv->connection);
+               ews_store_unset_connection_locked (ews_store);
                ews_store->priv->connection = g_object_ref (connection);
                g_mutex_unlock (&ews_store->priv->connection_lock);
 
@@ -1800,10 +1839,7 @@
                g_slist_free_full (foreign_fids, g_free);
        } else {
                g_mutex_lock (&ews_store->priv->connection_lock);
-               if (ews_store->priv->connection != NULL) {
-                       g_object_unref (ews_store->priv->connection);
-                       ews_store->priv->connection = NULL;
-               }
+               ews_store_unset_connection_locked (ews_store);
                g_mutex_unlock (&ews_store->priv->connection_lock);
 
                g_free (new_sync_state);
@@ -3563,26 +3599,9 @@
                ews_store->summary = NULL;
        }
 
-       if (ews_store->priv->connection != NULL) {
-               g_signal_handlers_disconnect_by_func (
-                       ews_store->priv->connection, 
camel_ews_store_server_notification_cb, ews_store);
-
-               if (ews_store->priv->listen_notifications) {
-                       stop_pending_updates (ews_store);
-
-                       if (ews_store->priv->subscription_key != 0) {
-                               e_ews_connection_disable_notifications_sync (
-                                       ews_store->priv->connection,
-                                       ews_store->priv->subscription_key);
-
-                               ews_store->priv->subscription_key = 0;
-                       }
-
-                       ews_store->priv->listen_notifications = FALSE;
-               }
-
-               g_clear_object (&ews_store->priv->connection);
-       }
+       g_mutex_lock (&ews_store->priv->connection_lock);
+       ews_store_unset_connection_locked (ews_store);
+       g_mutex_unlock (&ews_store->priv->connection_lock);
 
        g_slist_free_full (ews_store->priv->update_folder_names, g_free);
        ews_store->priv->update_folder_names = NULL;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/src/collection/e-ews-backend.c 
new/evolution-ews-3.16.4/src/collection/e-ews-backend.c
--- old/evolution-ews-3.16.3/src/collection/e-ews-backend.c     2015-03-23 
08:28:34.000000000 +0100
+++ new/evolution-ews-3.16.4/src/collection/e-ews-backend.c     2015-06-30 
12:41:43.000000000 +0200
@@ -188,6 +188,7 @@
 
        display_name = e_ews_folder_get_name (folder);
        e_source_set_display_name (source, display_name);
+       e_source_set_enabled (source, TRUE);
 
        switch (e_ews_folder_get_folder_type (folder)) {
                case E_EWS_FOLDER_TYPE_CALENDAR:
@@ -339,13 +340,8 @@
 ews_backend_sync_deleted_folders (EEwsBackend *backend,
                                   GSList *list)
 {
-       ECollectionBackend *collection_backend;
-       ESourceRegistryServer *server;
        GSList *link;
 
-       collection_backend = E_COLLECTION_BACKEND (backend);
-       server = e_collection_backend_ref_server (collection_backend);
-
        for (link = list; link != NULL; link = g_slist_next (link)) {
                const gchar *folder_id = link->data;
                ESource *source = NULL;
@@ -359,12 +355,10 @@
 
                /* This will trigger a "child-removed" signal and
                 * our handler will remove the hash table entry. */
-               e_source_registry_server_remove_source (server, source);
+               e_source_remove_sync (source, NULL, NULL);
 
                g_object_unref (source);
        }
-
-       g_object_unref (server);
 }
 
 static void
@@ -513,6 +507,7 @@
                                E_SERVER_SIDE_SOURCE (source), TRUE);
                        e_server_side_source_set_remote_deletable (
                                E_SERVER_SIDE_SOURCE (source), TRUE);
+                       e_source_set_enabled (source, TRUE);
                        e_source_registry_server_add_source (registry, source);
                } else {
                        GError *error = NULL;
@@ -1029,7 +1024,6 @@
        EEwsConnection *connection;
        CamelEwsSettings *ews_settings;
        ESourceAuthenticationResult result = E_SOURCE_AUTHENTICATION_ERROR;
-       gchar *hosturl;
 
        g_return_val_if_fail (E_IS_EWS_BACKEND (backend), 
E_SOURCE_AUTHENTICATION_ERROR);
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/evolution-ews-3.16.3/src/configuration/e-ews-config-utils.c 
new/evolution-ews-3.16.4/src/configuration/e-ews-config-utils.c
--- old/evolution-ews-3.16.3/src/configuration/e-ews-config-utils.c     
2015-03-23 08:28:34.000000000 +0100
+++ new/evolution-ews-3.16.4/src/configuration/e-ews-config-utils.c     
2015-06-17 18:07:41.000000000 +0200
@@ -1165,6 +1165,7 @@
        GtkActionGroup *action_group;
        EShell *shell;
        EShellWindow *shell_window;
+       ESource *source = NULL;
        const gchar *group;
        gboolean is_ews_source, is_online;
 
@@ -1182,7 +1183,28 @@
        else
                g_return_if_reached ();
 
-       is_ews_source = get_selected_ews_source (shell_view, NULL, NULL);
+       is_ews_source = get_selected_ews_source (shell_view, &source, NULL);
+
+       if (is_ews_source) {
+               if (!source || !e_source_has_extension (source, 
E_SOURCE_EXTENSION_EWS_FOLDER))
+                   is_ews_source = FALSE;
+
+               if (is_ews_source) {
+                       ESourceEwsFolder *ews_folder = e_source_get_extension 
(source, E_SOURCE_EXTENSION_EWS_FOLDER);
+
+                       /* Require both ChangeKey and folder's Id, but GAL can 
have a ':' in the Id,
+                          which should be ignored, because it's not a valid 
folder Id. */
+                       if (!e_source_ews_folder_get_id (ews_folder) ||
+                           g_strcmp0 (e_source_ews_folder_get_id (ews_folder), 
"") == 0 ||
+                           !e_source_ews_folder_get_change_key (ews_folder) ||
+                           g_strcmp0 (e_source_ews_folder_get_change_key 
(ews_folder), "") == 0 ||
+                           strchr (e_source_ews_folder_get_id (ews_folder), 
':') != NULL)
+                               is_ews_source = FALSE;
+               }
+       }
+
+       g_clear_object (&source);
+
        shell_window = e_shell_view_get_shell_window (shell_view);
        shell = e_shell_window_get_shell (shell_window);
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/src/server/e-ews-connection.c 
new/evolution-ews-3.16.4/src/server/e-ews-connection.c
--- old/evolution-ews-3.16.3/src/server/e-ews-connection.c      2015-04-21 
21:08:45.000000000 +0200
+++ new/evolution-ews-3.16.4/src/server/e-ews-connection.c      2015-06-30 
12:30:06.000000000 +0200
@@ -791,6 +791,16 @@
                        EWS_CONNECTION_ERROR_AUTHENTICATION_FAILED,
                        _("Authentication failed"));
                goto exit;
+       } else if (msg->status_code == SOUP_STATUS_CANT_RESOLVE ||
+                  msg->status_code == SOUP_STATUS_CANT_RESOLVE_PROXY ||
+                  msg->status_code == SOUP_STATUS_CANT_CONNECT ||
+                  msg->status_code == SOUP_STATUS_CANT_CONNECT_PROXY) {
+               g_simple_async_result_set_error (
+                       enode->simple,
+                       EWS_CONNECTION_ERROR,
+                       EWS_CONNECTION_ERROR_UNAVAILABLE,
+                       "%s", msg->reason_phrase);
+               goto exit;
        }
 
        response = e_soap_message_parse_response ((ESoapMessage *) msg);
@@ -2466,7 +2476,7 @@
 ews_dump_raw_soup_message (FILE *out, SoupMessageHeaders *hdrs,
                           SoupMessageBody *body)
 {
-       if (soup_message_body_get_accumulate (body)) {
+       if (body && soup_message_body_get_accumulate (body)) {
                SoupBuffer *buffer;
 
                buffer = soup_message_body_flatten (body);
@@ -2475,9 +2485,12 @@
 
        /* print body */
        fprintf (out, " =====================\n");
-       soup_message_headers_foreach (hdrs, print_header, out);
+       if (hdrs)
+               soup_message_headers_foreach (hdrs, print_header, out);
+       else
+               fprintf (out, " null headers\n");
        fputc ('\n', out);
-       if (body->data) {
+       if (body && body->data) {
                fputs (body->data, out);
                fputc ('\n', out);
        }
@@ -5145,7 +5158,7 @@
                case EWS_SEARCH_CONTACTS_AD:
                        return "ContactsActiveDirectory";
                default:
-                       g_assert_not_reached ();
+                       g_warn_if_reached ();
                        return NULL;
 
        }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/src/server/e-ews-debug.c 
new/evolution-ews-3.16.4/src/server/e-ews-debug.c
--- old/evolution-ews-3.16.3/src/server/e-ews-debug.c   2014-03-24 
10:28:36.000000000 +0100
+++ new/evolution-ews-3.16.4/src/server/e-ews-debug.c   2015-06-30 
12:28:18.000000000 +0200
@@ -65,7 +65,8 @@
 }
 
 EEwsServerVersion
-e_ews_debug_get_server_version_from_string (const gchar *version) {
+e_ews_debug_get_server_version_from_string (const gchar *version)
+{
        if (g_strcmp0 (version, "Exchange2007") == 0)
                return E_EWS_EXCHANGE_2007;
        else if (g_strcmp0 (version, "Exchange2007_SP1") == 0)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/src/server/e-ews-notification.c 
new/evolution-ews-3.16.4/src/server/e-ews-notification.c
--- old/evolution-ews-3.16.3/src/server/e-ews-notification.c    2015-05-22 
13:47:17.000000000 +0200
+++ new/evolution-ews-3.16.4/src/server/e-ews-notification.c    2015-06-30 
22:13:07.000000000 +0200
@@ -113,20 +113,11 @@
 EEwsNotification *
 e_ews_notification_new (EEwsConnection *connection)
 {
-       EEwsNotification *notification;
-       CamelEwsSettings *ews_settings;
-
        g_return_val_if_fail (E_IS_EWS_CONNECTION (connection), NULL);
 
-       notification = g_object_new (
+       return g_object_new (
                E_TYPE_EWS_NOTIFICATION,
                "connection", connection, NULL);
-
-       ews_settings = e_ews_connection_ref_settings (connection);
-
-       g_object_unref (ews_settings);
-
-       return notification;
 }
 
 static void
@@ -774,6 +765,13 @@
        return ret;
 }
 
+static void
+ews_notification_cancelled_cb (GCancellable *cancellable,
+                              SoupSession *session)
+{
+       soup_session_abort (session);
+}
+
 static gpointer
 e_ews_notification_get_events_thread (gpointer user_data)
 {
@@ -789,14 +787,22 @@
                goto exit;
 
        do {
+               gulong handler_id;
+
                if (g_cancellable_is_cancelled (td->cancellable))
                        goto exit;
 
+               handler_id = g_cancellable_connect (td->cancellable, G_CALLBACK 
(ews_notification_cancelled_cb),
+                       g_object_ref (td->notification->priv->soup_session), 
g_object_unref);
+
                ret = e_ews_notification_get_events_sync (
                                td->notification,
                                subscription_id);
 
-               if (!ret) {
+               if (handler_id > 0)
+                       g_cancellable_disconnect (td->cancellable, handler_id);
+
+               if (!ret && !g_cancellable_is_cancelled (td->cancellable)) {
                        g_debug ("%s: Failed to get notification events 
(SubscriptionId: '%s')", G_STRFUNC, subscription_id);
 
                        e_ews_notification_unsubscribe_folder_sync 
(td->notification, subscription_id);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/evolution-ews-3.16.3/src/server/ews-errors.h 
new/evolution-ews-3.16.4/src/server/ews-errors.h
--- old/evolution-ews-3.16.3/src/server/ews-errors.h    2014-10-30 
12:32:39.000000000 +0100
+++ new/evolution-ews-3.16.4/src/server/ews-errors.h    2015-06-25 
14:37:49.000000000 +0200
@@ -300,6 +300,7 @@
        /* Below this point are no longer direct translations of EWS errors */
        EWS_CONNECTION_ERROR_NORESPONSE,
        EWS_CONNECTION_ERROR_AUTHENTICATION_FAILED,
+       EWS_CONNECTION_ERROR_UNAVAILABLE,
        EWS_CONNECTION_ERROR_UNKNOWN
 };
 


Reply via email to