[xml] Line number value limit
- From: Csaba Raduly <rcsaba gmail com>
- To: xml gnome org
- Subject: [xml] Line number value limit
- Date: Thu, 12 Nov 2009 10:29:13 +0100
Why is the line number in xmlNode limited to an unsigned short ?
Doesn't libxml2 handle XML files with more than 65535 lines?
Also, the code which performs the truncation of the value in SAX2.c
(line 1601) is wrong.
if (ctxt->linenumbers) {
if (ctxt->input != NULL) {
if (ctxt->input->line < 65535)
ret->line = (short) ctxt->input->line;
else
ret->line = 65535;
}
}
The cast should be to (unsigned short)
Csaba
--
Life is complex, with real and imaginary parts
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]