[evolution-data-server] Bug 709838 - CamelDataCache: Empty cache file leads to deadlock



commit f07e7c1429ce6778f914191371d594f2596fe025
Author: Matthew Barnes <mbarnes redhat com>
Date:   Mon Nov 25 11:46:09 2013 -0500

    Bug 709838 - CamelDataCache: Empty cache file leads to deadlock
    
    camel_data_cache_get() forgot to abort the key reservation from its
    object bag when an empty cache file is detected.  This would eventually
    lead to a deadlock when attempting to add the same key later.
    
    This bug was mainly affecting HTML mails, when a remote image download
    got interrupted and left behind an empty file in the HTTP cache.

 camel/camel-data-cache.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
---
diff --git a/camel/camel-data-cache.c b/camel/camel-data-cache.c
index 5ac687e..2edd27e 100644
--- a/camel/camel-data-cache.c
+++ b/camel/camel-data-cache.c
@@ -449,6 +449,7 @@ camel_data_cache_get (CamelDataCache *cdc,
                g_set_error (
                        error, CAMEL_ERROR, CAMEL_ERROR_GENERIC,
                        "%s: %s", _("Empty cache file"), real);
+               camel_object_bag_abort (cdc->priv->busy_bag, real);
                goto exit;
        }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]