0.9.6claws15
authorChristoph Hohmann <reboot@gmx.ch>
Sun, 12 Oct 2003 15:37:56 +0000 (15:37 +0000)
committerChristoph Hohmann <reboot@gmx.ch>
Sun, 12 Oct 2003 15:37:56 +0000 (15:37 +0000)
* src/procmime.c
        fix crash caused by incorrect headers

ChangeLog.claws
configure.ac
src/procmime.c

index d89e8ef..6ee6da4 100644 (file)
@@ -1,4 +1,9 @@
-2003-10-10 [thorsten]  0.9.6claws14
+2003-10-12 [christoph] 0.9.6claws15
+
+       * src/procmime.c
+               fix crash caused by incorrect headers
+
+2003-10-10 [christoph] 0.9.6claws14
 
        * src/main.c
        * src/privacy.[ch]
index a226c96..ea19e5f 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=9
 MICRO_VERSION=6
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=14
+EXTRA_VERSION=15
 if test $EXTRA_VERSION -eq 0; then
     VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}claws
 else
index e1ff280..d827eef 100644 (file)
@@ -1071,14 +1071,15 @@ static void procmime_parse_content_type(const gchar *content_type, MimeInfo *mim
                gchar **parameters_parts;
 
                parameters_parts = g_strsplit(*strarray, "=", 1);
-               g_strdown(parameters_parts[0]);
-               if(parameters_parts[1][0] == '"')
-                       extract_quote(parameters_parts[1], '"');
-
-               g_hash_table_insert(mimeinfo->parameters,
-                                   g_strdup(parameters_parts[0]),
-                                   g_strdup(parameters_parts[1]));
-
+               if ((parameters_parts[0] != NULL) && (parameters_parts[1] != NULL)) {
+                       g_strdown(parameters_parts[0]);
+                       if(parameters_parts[1][0] == '"')
+                               extract_quote(parameters_parts[1], '"');
+
+                       g_hash_table_insert(mimeinfo->parameters,
+                                           g_strdup(parameters_parts[0]),
+                                           g_strdup(parameters_parts[1]));
+               }
                g_strfreev(parameters_parts);
        }