Mantis - Quercus
Viewing Issue Advanced Details
4647 crash always 06-30-11 12:18 07-06-11 02:05
jalmillategui  
 
normal  
feedback 4.0.11  
open  
none    
none  
0004647: java.lang.ArrayIndexOutOfBoundsException: 4 at at com.caucho.quercus.lib.regexp.RegexpModule$GroupNeighborMap.<init>
I'm trying to install openatrium a drupal based collaboration suite.

I have finished the install process using 4.0.11 and got the errors described in quercus_errors.txt (attached to this report) when visiting the start page

I then proceeded to update the quercus version to 4.0.18 and restore the site with the same results and errors.
I'm running quercus on Dell PE SC1430 with 4GB of ram. I'm using Ubuntu 11.04 x86_64, with sun java runtime: Java(TM) SE Runtime Environment (build 1.6.0_24-b07) and using glassfish 3.1 as the application server.

I also copied the default php.ini from ubuntu's php installation and configured the web.xml to look for it on the WEB-INF directory.
 quercus_errors.txt [^] (27,764 bytes) 06-30-11 12:18
 markdown.php code section.txt [^] (7,242 bytes) 07-04-11 11:47
 quercus_errors2.txt [^] (15,985 bytes) 07-05-11 17:25

Notes
(0005342)
domdorn   
07-04-11 09:36   
Could you please try to find out the regexp and input data tried at that page? It's not clear from the stacktrace and would speed things up a lot.
(0005343)
domdorn   
07-04-11 09:38   
the code should be around
 at MarkdownExtra_Parser._hashHTMLBlocks_inMarkdown(/home/jalmillategui/.glassfish-install-3.1/glassfish/domains/domain1/applications/atrium/profiles/openatrium/modules/contrib/markdown/markdown.php:1901)

please post the code at that position, comment it out and do a resin_var_dump() on the input that you are passing to the function. With that info we should be able to create a testcase.
(0005346)
jalmillategui   
07-04-11 11:52   
The code section specified (markdown.php:1901) is a do while loop. I have uploaded it here. There seems to exists serveral regex in the section:

'{^(?>.+?|\n(?!\n))*?(?<!`)'.$tag_re.'(?!`)}
'{^(?>.*\n)+?'.$tag_re.' *\n}'
'{^<(?:'.$this->block_tags_re.')\b}'
'{^<(?:'.$this->context_block_tags_re.')\b}'
'{^<(?:'.$this->clean_tags_re.')\b}'
'{^</?(?:'.$enclosing_tag_re.')\b}'

I will proceed to start generating the resin_var_dump() later today.

best,

Javier
(0005355)
jalmillategui   
07-05-11 17:29   
Hi All,

I tried to use resin_var_dump() which caused the stack trace shown in file quercus_errors2.txt

best,

Javier
(0005356)
domdorn   
07-06-11 02:05   
could you please try to get the complete regex and the complete input given to it?
thanks