Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#155 unescapeNewline does not work for capital letter N

Release
open
Ben Fortuna
Parsing (53)
5
2012-11-30
2012-11-30
Anonymous
No

I noticed problem with unescaping string "\N" in DESCRIPTION property of iCalendar source. Problem is that it was not unescaped.

If \n or \N appears in TEXT properties it should be interpreted as newline when parsing iCalendar source.
Now only \n is correcty interpreted.

I think the correction shold be made in class net.fortuna.ical4j.util.Strings in
private static final Pattern UNESCAPE_NEWLINE_PATTERN = Pattern.compile("(?<!\\\\)\\\\n");
It should be "(?<!\\\\)\\\\[nN]".

Tested in 1.0.4 release.

Discussion