Wednesday, 23 May 2012

small bug in nsurl.c

in the nsurl.c file, in  nsurl__get_string_markers, there an error in the 'ftp:' detection

original code:
} else if (off == SLEN("https") &&
(((*(pos - off + 0) == 'f') ||
 (*(pos - off + 0) == 'F')) &&
((*(pos - off + 1) == 't') ||
 (*(pos - off + 1) == 'T')) &&
((*(pos - off + 2) == 'p') ||
 (*(pos - off + 2) == 'P')))) {
marker.scheme_type = NSURL_SCHEME_FTP;

correct code:
} else if (off == SLEN("ftp") &&
(((*(pos - off + 0) == 'f') ||
 (*(pos - off + 0) == 'F')) &&
((*(pos - off + 1) == 't') ||
 (*(pos - off + 1) == 'T')) &&
((*(pos - off + 2) == 'p') ||
 (*(pos - off + 2) == 'P')))) {
marker.scheme_type = NSURL_SCHEME_FTP;

I send this mail here, because bugs@netsurf-browser.org is not responding

No comments:

Post a Comment