Bug #73517 [Asn->Fbk]: LineNr reports max at 65535 ... stays 65535

From: Date: Wed, 16 Nov 2016 18:37:11 +0000
Subject: Bug #73517 [Asn->Fbk]: LineNr reports max at 65535 ... stays 65535
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-205415@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=73517&edit=1

 ID:                 73517
 Updated by:         cmb@php.net
 Reported by:        johan at cti-computers dot be
 Summary:            LineNr reports max at 65535 ... stays 65535
-Status:             Assigned
+Status:             Feedback
 Type:               Bug
 Package:            Variables related
 Operating System:   OS X El Capitan 10.11.6
 PHP Version:        Next Minor Version
 Assigned To:        cmb
 Block user comment: N
 Private report:     N

 New Comment:

> OK. XAMPP 7.0.9-2 is now installed. PHP7 is included , and also
> LIBXML2.8.0

The official PHP windows binaries[1] are built against at least
libxml 2.9.2 as of PHP 7.0.0. What distros do is not our concern.
I suggest you contact <https://community.apachefriends.org/f/>.

Also, this is no help-desk. Please use one of the support channels
listed on <http://php.net/support.php>. Thanks.

[1] <http://windows.php.net/download/>


Previous Comments:
------------------------------------------------------------------------
[2016-11-16 17:34:29] johan at cti-computers dot be

OK. XAMPP 7.0.9-2 is now installed. PHP7 is included , and also LIBXML2.8.0
Not 2.9.0     What to do next ?
Any help ?   Where to download, how to install on MAC OS 10.11.6   ?

Thanks

------------------------------------------------------------------------
[2016-11-15 11:18:06] cmb@php.net

As of PHP 7.0.0 (and libxml >= 2.9.0) you can set
LIBXML_BIGLINES[1] to get the proper line numbers. Would that
solve the issue for you?

[1] <http://php.net/manual/en/libxml.constants.php>

------------------------------------------------------------------------
[2016-11-14 19:31:47] johan at cti-computers dot be

Description:
------------
---
From manual page: http://www.php.net/function.libxml-get-errors
---
When validating (xsd-schema) big XML ( > 10.000.000 lines )
> If errors are found in the XML on linenumbers above 65535,
the value for the next linenumbers stays at maximum value of 65535.

* using the function : libxml_display_error($error) 
* and reading the output for : $error->line;


PHP version 5.6.24

LIBXML Running on MAC ( with XAMPP 5-6-24.1 )
libXML Compiled Version	2.8.0
libXML Loaded Version	20800
libXML streams	enabled

Test script:
---------------
function libxml_display_errors() {
  $errors = libxml_get_errors();
  foreach ($errors as $error) {
    libxml_display_error($error);		
  }
  libxml_clear_errors();
}
function libxml_display_error($error)
{
   $_SESSION['rep_errcode'] = $error->code;
   $_SESSION['bme_linenr'] = "L ".(string)$error->line;
...
}
***************************************************
BUG = Linenr has max value 65535. 
All lines with errors are in the report, with correct linenr if this is < 65536. 

The other outputs are OK. No problems.
OK = $error->message;
OK = $error->code;

Expected result:
----------------
That the output for the linenumber doesn't stop at 65535.
 



------------------------------------------------------------------------



--
Edit this bug report at https://bugs.php.net/bug.php?id=73517&edit=1


Thread (5 messages)

« previous php.bugs (#205415) next »