[SyncEvolution] Broken UTF-8 item passed to backend (was Explicit type 'text/x-vcalendar' specified in command or item meta)

deloptes deloptes at gmail.com
Thu Oct 6 07:40:52 UTC 2016


Patrick Ohly wrote:

> I don't like magic - at least not in software engineering ;-}
> 
> So let's try to understand this a bit better. Compared to my proposed
> patch, you added "p=nextunfolded(p,aMimeMode,true)" before the
> "continue".
> 
> Without it, we enter the next loop iteration:
> 
> c=*p; // c should be = now

Yes exactly.

> if (isEndOfLineOrText(c) || (!escaped && aStructSep!=0 && (c==aStructSep
> || c==aAltSep))) break; // We haven't changed any of these, so it should
> continue. escaped=(!escaped) && (c=='\\'); // No change either. if
> (c=='=') { s=nextunfolded(p,aMimeMode,true); // Hmm, not quite the same...
> 

yes this is testing from position of p forward, without modifying p.

> Okay, I think I understand. The loop expects to start after skipping
> over line folding, so when we enter it pointing towards the soft line
> break =, it does the wrong thing. The additional nextunfolded() avoids
> that.

Yes this is also my understanding of that.

The last problem I have with all of that is double escaped '\n' and ','.

I'll try to find out where exactly it does this. It might be in the sysync
parser, but also in libkcal.

Thanks for the help.

regards

_______________________________________________
SyncEvolution mailing list
SyncEvolution at syncevolution.org
https://lists.syncevolution.org/mailman/listinfo/syncevolution



More information about the SyncEvolution mailing list