Fix crash when importing pine addressbook (reported on ML by dybulk@tri8.net).
authorDarko Koruga <darko@users.sourceforge.net>
Fri, 10 Jan 2003 06:41:52 +0000 (06:41 +0000)
committerDarko Koruga <darko@users.sourceforge.net>
Fri, 10 Jan 2003 06:41:52 +0000 (06:41 +0000)
ChangeLog.claws
configure.in
src/pine.c

index feeaae75639513aafb6bf2b5330abe74a6d73817..7b3cf993919e4e81a709728e6b613aa6a77d219c 100644 (file)
@@ -1,3 +1,9 @@
+2003-01-10 [darko]     0.8.8claws73
+
+       * src/pine.c
+               fix crash when importing address book entry
+               without a valid address
+
 2003-01-09 [alfons]    0.8.8claws72
 
        * src/inc.c
 2003-01-09 [alfons]    0.8.8claws72
 
        * src/inc.c
index 660e894ca9e834377112003270af21b1e7c0cf24..1f78d87d2448e932e49583b17478e67eaddfde8f 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=8
 MICRO_VERSION=8
 INTERFACE_AGE=0
 BINARY_AGE=0
 MICRO_VERSION=8
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws72
+EXTRA_VERSION=claws73
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl set $target
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl set $target
index c2096ac55913adc2245e07af7ec6166b35631d1b..7dac93ca9447b474aae1373179cdef82320915aa 100644 (file)
@@ -414,6 +414,8 @@ static void pine_parse_address( PineFile *pineFile, AddressCache *cache, Pine_Pa
        gchar *name;
        gint len;
 
        gchar *name;
        gint len;
 
+       g_return_if_fail( rec->address != NULL );
+
        buf = rec->address;
        while((atCh = strchr( buf, CHAR_AT )) != NULL) {
                name = pine_parse_name( buf, atCh, &bp, &ep );
        buf = rec->address;
        while((atCh = strchr( buf, CHAR_AT )) != NULL) {
                name = pine_parse_name( buf, atCh, &bp, &ep );
@@ -450,6 +452,8 @@ static ItemEMail *pine_insert_table(
        ItemEMail *email;
        gchar *key;
 
        ItemEMail *email;
        gchar *key;
 
+       g_return_if_fail( address != NULL );
+
        /* Test whether address already in hash table */
        key = g_strdup( address );
        g_strdown( key );
        /* Test whether address already in hash table */
        key = g_strdup( address );
        g_strdown( key );