diff options
-rw-r--r-- | mail/ChangeLog | 7 | ||||
-rw-r--r-- | mail/em-format-html.c | 4 |
2 files changed, 11 insertions, 0 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog index 58e8f63f12..8e71d1564c 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,5 +1,12 @@ 2009-02-11 Milan Crha <mcrha@redhat.com> + ** Fix for bug #569700 + + * em-format-html.c: (emfh_gethttp): + Stop reading from a network when operation was canceled. + +2009-02-11 Milan Crha <mcrha@redhat.com> + ** Fix for bug #333716 * em-format-html.c: (emfh_gethttp): diff --git a/mail/em-format-html.c b/mail/em-format-html.c index 21cbcf0e92..23926f8ed6 100644 --- a/mail/em-format-html.c +++ b/mail/em-format-html.c @@ -523,6 +523,10 @@ static void emfh_gethttp(struct _EMFormatHTMLJob *job, int cancelled) costream = camel_data_cache_add(emfh_http_cache, EMFH_HTTP_CACHE_PATH, job->u.uri, NULL); do { + if (camel_operation_cancel_check (NULL)) { + n = -1; + break; + } /* FIXME: progress reporting in percentage, can we get the length always? do we care? */ n = camel_stream_read(instream, buffer, sizeof (buffer)); if (n > 0) { |