Re: [evolution-patches] improve import of .vcf files containing multiple vcards



Are empty lines forbidden between a BEGIN:VCARD/END:VCARD block? (sorry,
I don't have time to decipher the rfc right now). If not, the current
code is equally broken ;)

This part of the patch:
-
-               contacts = g_list_append (contacts,
e_contact_new_from_vcard (temp));
+               g_strstrip (temp);
+               if ((temp != NULL) && (*temp != '\0')) {
+                       contacts = g_list_append (contacts,
e_contact_new_from_vcard (temp));
+               }

can't hurt (at least in my opinion ;) even if the rest doesn't go in. It
prevents evolution from creating an empty contact when there are
superfluous blank line at the end of the file for example.

Christophe

Le sam, 01/05/2004 à 09:11 -0700, Chris Toshok a écrit :
> this won't work, as vcards can actually contain other embedded vcards.
> Of course, those vcards probably break the parser, but we shouldn't be
> breaking them elsewhere as well.
> 
> Chris
> 
> On Sat, 2004-05-01 at 14:25 +0200, Christophe Fergeau wrote:
> > Hi,
> > 
> > eab_contact_list_from_string currently expects vcards to be separated by
> > 2 new lines characters when they are concatenated in a single file. The
> > attached patch looks for an "END:VCARD" string instead.
> > 
> > Christophe
> _______________________________________________
> Evolution-patches mailing list
> Evolution-patches lists ximian com
> http://lists.ximian.com/mailman/listinfo/evolution-patches
> 
> 

Attachment: signature.asc
Description: Ceci est une partie de message =?ISO-8859-1?Q?num=E9riquement?= =?ISO-8859-1?Q?_sign=E9e?=



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]