FAQ
Edit report at https://pear.php.net/bugs/bug.php?id=15924&edit=1

ID: 15924
Updated by: daniel.oconnor@gmail.com
Reported By: shamantobi at gmail dot com
Summary: Warning: split() [function.split]: Invalid preceding
regular expression
-Status: Assigned
+Status: Feedback
Type: Bug
Package: Structures_BibTex
Operating System: Linux
PHP Version: 5.2.5
Assigned To: hugoki
Roadmap Versions:
New Comment:

-Status: Assigned
+Status: Feedback
Thank you for taking the time to report a problem with the package.
This problem may have been already fixed by a previous change that
is in the SVN of the package. Please checking out the SVN
repository of this package and upgrade

svn checkout
svn.php.net/repository/pear/packages/Structures_BibTex/trunk
pear upgrade package2.xml

or

pear upgrade package.xml

If you are able to reproduce the bug with the latest SVN,
please change the status back to "Open".
Again, thank you for your continued support of PEAR.

Have got OlleOlleOlle's patch applied for this anyway - can you verify
if it happens
with explode() now in use?


Previous Comments:
------------------------------------------------------------------------

[2010-08-19 22:31:09] olleolleolle

Added #patch bug:15924;patch:using_explode.patch;revision:1282257069;.

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

[2009-03-01 22:38:54] doconnor

-Assigned To:
+Assigned To: hugoki


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

[2009-02-20 21:11:48] lgalarra

Description:
------------
Dear developers:

My project (http://joomla-research.com) is using this library to parse
sets of Bibtex entries, however a user reported a really strange bug in
which the parse method could not retrieve the type of entry
('entryType' property in the result array). By debugging the code I
found the following problem in line 423 :

split() [function.split]: Invalid preceding regular expression in ...
line 423

which produces variable $arr to be empty.

I check PHP documentation for function split and found that this takes a
pattern as first parameter which made me realize, regexp special
characters should be escaped. The mentioned line says:

$arr = split('{', $entry);

I changed it to:

$arr = split('\{', $entry);

and the bug was gone. I have to add that my user is using PHP 5.2.6 (Why
does it not appear in the list?) It is the first time something similar
happen. Furthermore, this change did not affect other installations.

Test script:
---------------


Expected result:
----------------


Actual result:
--------------

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

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppear-bugs @
categoriesphp
postedJan 17, '12 at 2:05p
activeJan 17, '12 at 2:05p
posts1
users1
websitepear.php.net

1 user in discussion

Daniel Oconnor: 1 post

People

Translate

site design / logo © 2021 Grokbase