View Issue Details

IDProjectCategoryView StatusLast Update
0000797SOGoWeb Calendarpublic2012-03-16 19:02
Reporterluca Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version1.3.1 
Summary0000797: Possibly wrong data causes problem with recurring events in web interface
Description

The attached backup file (edited to contain just one record, by substituting the "/Users/luca/Calendar/personal" with an existing user it should be possible to use "sogo-tool restore -F"), coming from a sogo 1.2.1 nightly (20100323), contains a wrong couple of dates in the EXDATE field and an empty RDATE field.
"sogo-tool restore" complains about a wrong month, stops for a (relatively long) while but the restore succeeds anyway.
However double clicking on the event in the web interface, just opens the confirmation window (the one asking if it should edit just this occurrence or all of them) that stays blank, and after a long while it shows the message "An error occurred during object publishing the requested object could not be found!".
The only way to "fix" this event is to edit it in lightning (note that even lighting behaves strangely: double click on the event does nothing, add a new event and only then the previous window asking which occurrence to edit appears).
Even removing/fixing the wrong EXDATE from the backup doesn't solve the issue (but the object not found windows appears right away instead of taking a long time).

Additional Information

These are the log messages when trying to access the event with the wrong EXDATE:

2010-09-02 10:52:19.320 sogod[7844] File NSCalendarDate.m: 1440. In [NSCalendarDate -initWithYear:month:day:hour:minute:second:timeZone:] invalid month given - 4294967295
2010-09-02 10:52:19.350 sogod[7843] WOCompoundElement: pool embedding is on.
2010-09-02 10:52:19.351 sogod[7843] WOCompoundElement: id logging is on.
2010-09-02 10:52:19.376 sogod[7842] WOCompoundElement: pool embedding is on.
2010-09-02 10:52:19.376 sogod[7842] WOCompoundElement: id logging is on.
127.0.0.1 - - [02/Sep/2010:10:52:19 GMT] "POST /SOGo/so/luca/Calendar/dateselector?day=20100922 HTTP/1.1" 200 753/0 0.576 9355 91% 1M
127.0.0.1 - - [02/Sep/2010:10:52:19 GMT] "POST /SOGo/so/luca/Calendar/dateselector?day=20100922 HTTP/1.1" 200 753/0 0.526 9355 91% 1M
2010-09-02 10:52:19.802 sogod[7842] File NSCalendarDate.m: 1440. In [NSCalendarDate -initWithYear:month:day:hour:minute:second:timeZone:] invalid month given - 4294967295

Then after 1 minute or so:

2010-09-02 10:53:40.564 sogod[7844] File NSCalendarDate.m: 1440. In [NSCalendarDate -initWithYear:month:day:hour:minute:second:timeZone:] invalid month given - 4294967295
2010-09-02 10:53:41.097 sogod[7842] File NSCalendarDate.m: 1440. In [NSCalendarDate -initWithYear:month:day:hour:minute:second:timeZone:] invalid month given - 4294967295

Then after 20 seconds more (when the "object not found" appears):

2010-09-02 10:55:02.077 sogod[7844] WOCompoundElement: pool embedding is on.
2010-09-02 10:55:02.078 sogod[7844] WOCompoundElement: id logging is on.
127.0.0.1 - - [02/Sep/2010:10:55:02 GMT] "POST /SOGo/so/luca/Calendar/personal/1073742958/occurence1285106400/view HTTP/1.1" 404 208/0 163.224 - - 1M
127.0.0.1 - - [02/Sep/2010:10:55:02 GMT] "GET /SOGo/so/luca/Calendar/personal/1073742958/occurence1285106400/confirmEditing HTTP/1.1" 404 208/0 162.717 - - 184K

These are the messages once the EXTDATE has been removed:

127.0.0.1 - - [02/Sep/2010:10:56:53 GMT] "POST /SOGo/so/luca/Calendar/personal/1073742958/occurence1285106400/view HTTP/1.1" 404 208/0 0.218 - - 32K
127.0.0.1 - - [02/Sep/2010:10:56:54 GMT] "GET /SOGo/so/luca/Calendar/personal/1073742958/occurence1285106400/confirmEditing HTTP/1.1" 404 208/0 0.089 - - 0

TagsNo tags attached.

Activities

2010-09-02 08:58

 

test-backup (979 bytes)   
{
    tables = {
	"/Users/luca/Calendar/personal" = {
	    acl = {
	    };
	    displayname = "Calendario Personal";
	    records = (
		{
		    c_content = "BEGIN:VCALENDAR
VERSION:1.0
TZ:+0100
DAYLIGHT:TRUE;+0200;20090329T020000;20091025T030000;;
DAYLIGHT:TRUE;+0200;20100328T020000;20101031T030000;;
DAYLIGHT:TRUE;+0200;20110327T020000;20111030T030000;;
DAYLIGHT:TRUE;+0200;20120325T020000;20121028T030000;;
DAYLIGHT:TRUE;+0200;20130331T020000;20131027T030000;;
DAYLIGHT:TRUE;+0200;20140330T020000;20141026T030000;;
DAYLIGHT:TRUE;+0200;20150329T020000;20151025T030000;;
BEGIN:VEVENT
UID:1073742958
X-FUNAMBOL-ALLDAY:1
DTSTART:20090522
DTEND:20090523
X-MICROSOFT-CDO-BUSYSTATUS:0
CATEGORIES:
DESCRIPTION:
LOCATION:
STATUS:0
SUMMARY:XXXXXXX
CLASS:PUBLIC
RRULE:FREQ=MONTHLY;INTERVAL=1;BYMONTHDAY=22;COUNT=0
EXDATE:2009-11-22;2010-05-22
RDATE:
X-FUNAMBOL-AALARMOPTIONS:4
END:VEVENT
END:VCALENDAR
";
		    c_name = 1073742958;
		},
	    );
	};
    };
}
test-backup (979 bytes)   
francis

francis

2010-10-07 14:56

administrator   ~0001555

Can you try with a recent nightly build?

luca

luca

2010-10-07 15:15

reporter   ~0001557

Last edited: 2010-10-07 15:17

Not really: any version after 1.2.1 causes a "stack smashing" with yearly events if compiled with "-fstack-protector" (which is the default on my distribution).
I didn't report it as a bug since I got no feedback from the mailing list.

See this thread for more details:

http://www.mail-archive.com/users@sogo.nu/msg01647.html

(edit: mantis mangles the above url)

I compiled NGCards with -fno-stack-protector to get rid of the "stack smashing", but everything else works fine with it, so I think that's just hiding the issue.

francis

francis

2010-10-29 13:55

administrator   ~0001662

The recurrence rule of your test event defines a count of zero, which is invalid. I pushed a fix yesterday that handles this case. When you have the chance, try to compile from trunk with stack-protector.

Thanks!

luca

luca

2011-01-27 13:45

reporter   ~0002057

I just tried with sogo 1.3.5 and it still fails (works with -fno-stack-protector)

luca

luca

2011-01-27 14:01

reporter   ~0002060

The last comment refers only to the stack smashing. It is now possible to edit the event.

ludovic

ludovic

2011-03-06 18:39

administrator   ~0002202

I've compiled SOPE/SOGo with -fstack-protector and I do not have any of the issues you describe above with your test event.

luca

luca

2011-03-07 23:29

reporter   ~0002211

Well, that's strange, I can reproduce the stack smashing if I compile NGCards without -fno-stack-protector.
Maybe it's been fixed meanwhile.

buzzdee

buzzdee

2011-07-13 07:47

reporter   ~0002697

I tried the calendar entry on a 1.3.7a sope/sogo on OpenBSD/i386, which enables the stack protector per default, you have to disable it if you do not want it.

No crash happened for me, I was able to edit the appointment.

luca

luca

2011-07-13 07:54

reporter   ~0002698

Last edited: 2011-07-13 07:55

Probably this specific kind of event has been fixed (I'm still with 1.3.5a, no time to play with sogo recently).
I just pointed you to this bug because I don't think it's a coincidence that the stack protector you reported in bug 0001370 happens in the same place (iCalMonthlyRecurrenceCalculator).

Edit: oops, the bug you're monitoring, you didn't report it.

ludovic

ludovic

2012-03-16 19:02

administrator   ~0003590

No changes / updates in months, closing.

Issue History

Date Modified Username Field Change
2010-09-02 08:58 luca New Issue
2010-09-02 08:58 luca File Added: test-backup
2010-10-07 14:56 francis Note Added: 0001555
2010-10-07 14:56 francis Status new => feedback
2010-10-07 15:15 luca Note Added: 0001557
2010-10-07 15:16 luca Note Edited: 0001557
2010-10-07 15:17 luca Note Edited: 0001557
2010-10-29 13:55 francis Note Added: 0001662
2011-01-27 13:45 luca Note Added: 0002057
2011-01-27 14:01 luca Note Added: 0002060
2011-03-06 18:39 ludovic Note Added: 0002202
2011-03-07 23:29 luca Note Added: 0002211
2011-07-13 07:47 buzzdee Note Added: 0002697
2011-07-13 07:54 luca Note Added: 0002698
2011-07-13 07:55 luca Note Edited: 0002698
2012-03-16 19:02 ludovic Note Added: 0003590
2012-03-16 19:02 ludovic Status feedback => closed
2012-03-16 19:02 ludovic Resolution open => fixed