diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2001-08-23 01:58:44 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2001-08-23 01:58:44 +0800 |
commit | b64eb59f2823e27341d21613a8f84f1bf6e58e98 (patch) | |
tree | 5cb57c7fc089093a955c27aef0e9212c202eaef1 /camel | |
parent | e84ebd2e0a9ff78773bdd2cecfe0f2b6ebc2c252 (diff) | |
download | gsoc2013-evolution-b64eb59f2823e27341d21613a8f84f1bf6e58e98.tar.gz gsoc2013-evolution-b64eb59f2823e27341d21613a8f84f1bf6e58e98.tar.zst gsoc2013-evolution-b64eb59f2823e27341d21613a8f84f1bf6e58e98.zip |
Oops. Fixed a mis-use of GPtrArray. If we set_size, then using
2001-08-22 Jeffrey Stedfast <fejj@ximian.com>
* providers/pop3/camel-pop3-folder.c (pop3_generate_uids):
Oops. Fixed a mis-use of GPtrArray. If we set_size, then using
g_ptr_array_add will assume `size' elements have already been
initialized and will start appending on to the end.
svn path=/trunk/; revision=12385
Diffstat (limited to 'camel')
-rw-r--r-- | camel/ChangeLog | 7 | ||||
-rw-r--r-- | camel/providers/pop3/camel-pop3-folder.c | 6 |
2 files changed, 11 insertions, 2 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog index 5eaf869253..a0e6e07768 100644 --- a/camel/ChangeLog +++ b/camel/ChangeLog @@ -1,3 +1,10 @@ +2001-08-22 Jeffrey Stedfast <fejj@ximian.com> + + * providers/pop3/camel-pop3-folder.c (pop3_generate_uids): + Oops. Fixed a mis-use of GPtrArray. If we set_size, then using + g_ptr_array_add will assume `size' elements have already been + initialized and will start appending on to the end. + 2001-08-21 Jeffrey Stedfast <fejj@ximian.com> * camel-pgp-context.c (pgp_verify): Turn on --batch and reenable diff --git a/camel/providers/pop3/camel-pop3-folder.c b/camel/providers/pop3/camel-pop3-folder.c index f9f53c7e57..6a7a1e6706 100644 --- a/camel/providers/pop3/camel-pop3-folder.c +++ b/camel/providers/pop3/camel-pop3-folder.c @@ -163,10 +163,12 @@ pop3_generate_uids (CamelFolder *folder, int count, CamelException *ex) camel_object_unref (CAMEL_OBJECT (stream)); uid = base64_encode_simple (digest, 16); - if (uid && *uid) - g_ptr_array_add (uids, uid); + uids->pdata[i] = uid; } + if (i < count) + g_ptr_array_set_size (uids, i); + return uids; exception: |