From: A. <rem...@ya...> - 2006-01-11 09:33:16
|
Here is what I've done so far. I applied the diff from DIFF 1 on opensync/formats/vformats-xml/xml-vcal.c in order to avoid the SIGSEV. Then I restarted the sync, and I got the TRACE 1. This time, the call to vcal_parse_attributes is finishing correctly but I got a very short xml out of it. So, I decided to try something to get more xml. Thus, the diff number 2, getting to the trace number 2. In term of xml, it's a lot better. But naturally, now I have another problem related to the following message, I got on the error output. (process:6753): GLib-CRITICAL **: g_hash_table_lookup: assertion `hash_table !=3D NULL' failed ** ERROR **: file opensync_member.c: line 1206 (osync_member_commit_change): assertion failed: (change) aborting... will try to find what it means later (but if someone knows already, thanks for the input :-) regards RemyA DIFF 1: [amourouxr@remya opensync]$ svn diff formats/vformats-xml/xml-vcal.c Index: formats/vformats-xml/xml-vcal.c =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- formats/vformats-xml/xml-vcal.c (r=C3=A9vision 778) +++ formats/vformats-xml/xml-vcal.c (copie de travail) @@ -672,8 +672,8 @@ { osync_trace(TRACE_ENTRY, "%s(%p, %p)", __func__, attributes, root); - GList *a =3D NULL; - for (a =3D *attributes; a; a =3D a->next) { + GList *a =3D *attributes; + while (a) { VFormatAttribute *attr =3D a->data; if (!strcmp(vformat_attribute_get_name(attr), "BEGIN")) { @@ -707,6 +707,11 @@ return; } else vcal_handle_attribute(table, paramtable, root, attr); + + // time to "increment" + if(a) { + a =3D a->next; + } } osync_trace(TRACE_EXIT, "%s: Done", __func__); } DIFF 2: [amourouxr@remya opensync]$ svn diff formats/vformats-xml/vformat.c Index: formats/vformats-xml/vformat.c =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- formats/vformats-xml/vformat.c (r=C3=A9vision 778) +++ formats/vformats-xml/vformat.c (copie de travail) @@ -496,10 +496,11 @@ VFormatAttribute *attr; /* first validate the string is valid utf8 */ - if (!g_utf8_validate (buf, -1, (const char **)&end)) { + while (!g_utf8_validate (buf, -1, (const char **)&end)) { /* if the string isn't valid, we parse as much as we can from it */ g_warning ("invalid utf8 passed to VFormat. Limping along."); - *end =3D '\0'; + // *end =3D '\0'; + *end =3D ' '; } buf =3D _fold_lines (buf); TRACE 1:=20 [1136900506.519306] = Input vcal is: BEGIN:VCALENDAR PRODID:-//Ximian//NONSGML Evolution Calendar//EN VERSION:2.0 METHOD:PUBLISH BEGIN:VEVENT ATTENDEE;CN=3DR=C3=A9my Amouroux;ROLE=3DREQ-PARTICIPANT;RSVP=3DTRUE; PARTSTAT=3DACCEPTED:MAILTO:rem...@ke... ORGANIZER:MAILTO:va...@am... DTSTART:20050922T060000Z DTEND:20050922T080000Z TRANSP:OPAQUE SEQUENCE:0 UID: 040000008200E00074C5B7101A82E0080000000010E4575FC9AFC5010000000000000000= 10 000000B6F0CDF8F87227418E1C2A0DBE2BD607 DTSTAMP:20050902T121947Z DESCRIPTION:Quand : jeudi 22 septembre 2005 08:00-10:00 (GMT+01:00) Bruxelles\, Copenhague\, Madrid\, Paris.\n\n*~*~*~*~*~*~*~*~*~*\n\nTMV S= t Egreve 04/76/75/21/34\n\n\n\n SUMMARY:Depannage Volet Budendorf PRIORITY:5 CLASS:PUBLIC X-MICROSOFT-CDO-REPLYTIME:20050902T135144Z CREATED:20050902T135144 LAST-MODIFIED:20050902T135144 END:VEVENT END:VCALENDAR [1136900506.519512] = Creating xml doc [1136900506.519561] = parsing attributes [1136900506.519606] = >>>>>>> vcal_parse_attributes(0xb6be6108, 0xc1f7818) [1136900506.519652] = >>>>>>> vcal_handle_attribute(0xc1f0548, 0xc1f7818, 0xc1f= 8320:PRODID) [1136900506.519698] = Hook is: 0x1 [1136900506.519741] = <<<<<<< vcal_handle_attribute: Ignored [1136900506.519787] = >>>>>>> vcal_handle_attribute(0xc1f0548, 0xc1f7818, 0xc1f= 1678:VERSION) [1136900506.519832] = Hook is: 0x1 [1136900506.519876] = <<<<<<< vcal_handle_attribute: Ignored [1136900506.519920] = >>>>>>> vcal_handle_attribute(0xc1f0548, 0xc1f7818, 0xc1f= 6cf8:METHOD) [1136900506.519965] = Hook is: 0x390c3c [1136900506.520009] = Handling method attribute [1136900506.520058] = <<<<<<< vcal_handle_attribute [1136900506.520107] = >>>>>>> vcal_parse_attributes(0xb6be60c8, 0xc1f7d40) [1136900506.520152] = <<<<<<< vcal_parse_attributes: Done [1136900506.520195] = <<<<<<< vcal_parse_attributes: Done [1136900506.520281] = Output XML is: <?xml version=3D"1.0"?> <vcal> <Method> <Content>PUBLISH</Content> </Method> <Event/> </vcal> TRACE 2: [1136969487.644659] = Output XML is: <?xml version=3D"1.0"?> <vcal> <Method> <Content>PUBLISH</Content> </Method> <Event> <Attendee> <Content>MAILTO:rem...@ke...</Content> <CommonName>R my Amouroux</CommonName> <Role>REQ-PARTICIPANT</Role> <RSVP>TRUE</RSVP> <PartStat>ACCEPTED</PartStat> </Attendee> <DateStarted> <Content>20050922T060000Z</Content> </DateStarted> <DateEnd> <Content>20050922T080000Z</Content> </DateEnd> <Transparency> <Content>OPAQUE</Content> </Transparency> <Sequence> <Content>0</Content> </Sequence> <DateCalendarCreated> <Content>20050902T121947Z</Content> </DateCalendarCreated> <Description> <Content>Quand : jeudi 22 septembre 2005 08:00-10:00 (GMT+01:00) Br= uxelles, Copenhague, Madrid, Paris. *~*~*~*~*~*~*~*~*~* TMV St Egreve 04/76/75/21/34 </Content> </Description> <Summary> <Content>Depannage Volet Budendorf</Content> </Summary> <Priority> <Content>5</Content> </Priority> <Class> <Content>PUBLIC</Content> </Class> <UnknownNode> <NodeName>X-MICROSOFT-CDO-REPLYTIME</NodeName> <Content>20050902T135144Z</Content> </UnknownNode> <DateCreated> <Content>20050902T135144</Content> </DateCreated> <LastModified> <Content>20050902T135144</Content> </LastModified> </Event> </vcal> [1136969487.644709] <= <<<<<< conv_vcal_to_xml: TRUE Le lundi 09 janvier 2006 =C3=A0 19:35 +0100, R=C3=A9my Amouroux a =C3=A9c= rit :=20 > Hello >=20 > I had a SIGSEV during my first sync between evo2 and the file-sync > plugin. >=20 > My investigation sofar shows that it is related to the presence of > non-utf8 characters in the stuff sent by evo2. --=20 E-mail : Re...@Am... Web : http://www.amouroux.org/ Yahoo Id: kelkooremya |