[evolution-data-server/evolution-data-server-3-12] Bug 730979 - [IMAPx] Quota information is not read properly
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server/evolution-data-server-3-12] Bug 730979 - [IMAPx] Quota information is not read properly
- Date: Fri, 30 May 2014 17:18:32 +0000 (UTC)
commit 07b15a0e8656857b5c37b599f44fb4bdee611605
Author: Milan Crha <mcrha redhat com>
Date: Fri May 30 19:15:42 2014 +0200
Bug 730979 - [IMAPx] Quota information is not read properly
This is regression after a fix for bug #722275.
camel/providers/imapx/camel-imapx-input-stream.c | 92 +++++++++++----------
1 files changed, 48 insertions(+), 44 deletions(-)
---
diff --git a/camel/providers/imapx/camel-imapx-input-stream.c
b/camel/providers/imapx/camel-imapx-input-stream.c
index d9dfed6..2a383c7 100644
--- a/camel/providers/imapx/camel-imapx-input-stream.c
+++ b/camel/providers/imapx/camel-imapx-input-stream.c
@@ -368,54 +368,58 @@ camel_imapx_input_stream_astring (CamelIMAPXInputStream *is,
p = is->priv->ptr;
e = is->priv->end;
- /* skip whitespace/prefill buffer */
- do {
- while (p >= e ) {
- is->priv->ptr = p;
- if (imapx_input_stream_fill (is, cancellable, error) == IMAPX_TOK_ERROR)
- return FALSE;
- p = is->priv->ptr;
- e = is->priv->end;
- }
- c = *p++;
- } while (c == ' ' || c == '\r');
-
- if (c == '\"' || c == '{') {
+ if (is->priv->unget) {
tok = camel_imapx_input_stream_token (is, data, &len, cancellable, error);
} else {
- guchar *o, *oe;
-
- tok = IMAPX_TOK_STRING;
-
- /* <any %x01-7F except "(){ " / %x00-1F / %x7F > */
- o = is->priv->tokenbuf;
- oe = is->priv->tokenbuf + is->priv->bufsize - 1;
- *o++ = c;
- while (1) {
- while (p < e) {
- c = *p++;
- if (c <= 0x1f || c == 0x7f || c == '(' || c == ')' || c == '{' || c == ' ') {
- if (c == ' ' || c == '\r')
- is->priv->ptr = p;
- else
- is->priv->ptr = p - 1;
- *o = 0;
- *data = is->priv->tokenbuf;
- return TRUE;
- }
+ /* skip whitespace/prefill buffer */
+ do {
+ while (p >= e ) {
+ is->priv->ptr = p;
+ if (imapx_input_stream_fill (is, cancellable, error) == IMAPX_TOK_ERROR)
+ return FALSE;
+ p = is->priv->ptr;
+ e = is->priv->end;
+ }
+ c = *p++;
+ } while (c == ' ' || c == '\r');
+
+ if (c == '\"' || c == '{') {
+ tok = camel_imapx_input_stream_token (is, data, &len, cancellable, error);
+ } else {
+ guchar *o, *oe;
+
+ tok = IMAPX_TOK_STRING;
+
+ /* <any %x01-7F except "(){ " / %x00-1F / %x7F > */
+ o = is->priv->tokenbuf;
+ oe = is->priv->tokenbuf + is->priv->bufsize - 1;
+ *o++ = c;
+ while (1) {
+ while (p < e) {
+ c = *p++;
+ if (c <= 0x1f || c == 0x7f || c == '(' || c == ')' || c == '{' || c
== ' ') {
+ if (c == ' ' || c == '\r')
+ is->priv->ptr = p;
+ else
+ is->priv->ptr = p - 1;
+ *o = 0;
+ *data = is->priv->tokenbuf;
+ return TRUE;
+ }
- if (o >= oe) {
- camel_imapx_input_stream_grow (is, 0, &p, &o);
- oe = is->priv->tokenbuf + is->priv->bufsize - 1;
- e = is->priv->end;
+ if (o >= oe) {
+ camel_imapx_input_stream_grow (is, 0, &p, &o);
+ oe = is->priv->tokenbuf + is->priv->bufsize - 1;
+ e = is->priv->end;
+ }
+ *o++ = c;
}
- *o++ = c;
+ is->priv->ptr = p;
+ if (imapx_input_stream_fill (is, cancellable, error) == IMAPX_TOK_ERROR)
+ return FALSE;
+ p = is->priv->ptr;
+ e = is->priv->end;
}
- is->priv->ptr = p;
- if (imapx_input_stream_fill (is, cancellable, error) == IMAPX_TOK_ERROR)
- return FALSE;
- p = is->priv->ptr;
- e = is->priv->end;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]