diff options
| author | NotZed <NotZed@HelixCode.com> | 2000-02-28 23:26:13 +0000 |
|---|---|---|
| committer | Michael Zucci <zucchi@src.gnome.org> | 2000-02-28 23:26:13 +0000 |
| commit | 187cd3e261a8ae104a7f146ae0c5d20a1b342ded (patch) | |
| tree | abc30ef28d1e174750de8484da68f8237ca97fcc /camel/string-utils.c | |
| parent | df91436f8328f0760cc56d81c428900c4c86c6fe (diff) | |
| download | evolution-data-server-187cd3e261a8ae104a7f146ae0c5d20a1b342ded.tar.gz | |
Fix a bunch of serious small bugs.
2000-02-28 NotZed <NotZed@HelixCode.com>
* camel-mime-part.c (_parse_header_pair): Dont free this either.
* camel-medium.c (_remove_header): Ugh, dont free the header
before we actually remove it.
(_add_header): Ugh, dont free hashtable entries which may be
duplicated (hash_insert _will_ reference that memory).
* string-utils.c (string_trim): Trimming a 0-length string is not
an error.
* camel-mime-message.c (_parse_header_pair): Fixed very broken
memory handling of header_name/value.
* providers/mbox/camel-mbox-utils.c (camel_mbox_write_xev):
Initialise end_of_last_message always.
(camel_mbox_copy_file_chunk): Stop trying to read if we run out of
data, rather than looping forever.
* providers/mbox/camel-mbox-folder.c (_init): Set search cap on.
(_open): Call parent class to perform open. Remove folder-open
check to parent instead.
(_create): open takes a creation mask, dont use umask to try and
set the open mode.
(_delete): Dont bother checking folder==NULL, its already been
checked on the external interface (changed to an assertion, this
would have to be a camel bug).
(_delete_messages): Likewise.
(_create): Ditto.
(_init): Dont go and clear all the paths and shit that the parent
open just setup for us.
(_delete_messages): Get rid of more umask stuff.
(_append_message): Make sure we pass file mode to open with create.
(_append_message): Cleaned up some indenting to make it readable.
Diffstat (limited to 'camel/string-utils.c')
| -rw-r--r-- | camel/string-utils.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/camel/string-utils.c b/camel/string-utils.c index 757a90719..1f6d156d0 100644 --- a/camel/string-utils.c +++ b/camel/string-utils.c @@ -228,7 +228,8 @@ string_trim (gchar *string, const gchar *trim_chars, StringTrimOption options) g_return_if_fail (string); length = strlen (string); - g_return_if_fail (length > 0); + if (length==0) + return; first_ok = 0; last_ok = length - 1; |
