Guido Van Hoecke <gui...@gmail.com> writes:

[...]

> My ics file had a.o. my elder sister's birthday, and unfortunately her's
> as well as mine is (way) before the start of the epoch, so mktime
> returns a negative timestamp at line 63 and strftime at line 143 doesn't
> grok it.

Ah, I see.  The script should at least not break just because some of us
(me included) are older than Unix... ;-)

The fix should be straightforward.  Could you try adding the lines

   if (timestamp < 0) timestamp = 0;

after the call to mktime in the datetimestamp function?  This should at
least make the script not crap out although obviously the date will be
wrong (set to start of epoch).  If this works, I will update the script
on Worg and put in a warning message of some sort, maybe even in the
entry itself.

Suggestions on how to handle this case would be welcome, of course.

-- 
: Eric S Fraga, GnuPG: 0xC89193D8FFFCF67D
: in Emacs 24.3.50.1 and Org release_8.0.2-68-g40635b


Reply via email to