|
Mantis - Quercus
|
|||||
| Viewing Issue Advanced Details | |||||
|
|
|||||
| ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
| 4056 | major | sometimes | 05-28-10 15:26 | 05-28-10 15:26 | |
|
|
|||||
| Reporter: | sblommers | Platform: | Linux | ||
| Assigned To: | OS: | Ubuntu | |||
| Priority: | normal | OS Version: | 10.04 | ||
| Status: | new | Product Version: | 4.0.7 | ||
| Product Build: | SVN (latest) | Resolution: | open | ||
| Projection: | none | ||||
| ETA: | none | Fixed in Version: | |||
|
|
|||||
| Summary: | 0004056: Env.getCookies crashing on _request (nullpointer exception) when in scriptcontext mode (JSR) | ||||
| Description: |
Running Drupal 6.16 functions in SC mode (running node_load etc from script). Sometimes Env.getCookies is called but in this SC the request and session variables are null (not initialized). I don't know if I'm doing something wrong here but I created a patch for it to not make it crash. |
||||
| Steps To Reproduce: | Get cookies in php script when there is no servlet serving the php files but a QuercusEngine or using javax.script .. | ||||
| Additional Information: |
DIFF against latest SVN 7166 diff -r 0c58513dd2cb modules/quercus/src/com/caucho/quercus/env/Env.java --- a/modules/quercus/src/com/caucho/quercus/env/Env.java Fri May 28 11:54:18 2010 +0200 +++ b/modules/quercus/src/com/caucho/quercus/env/Env.java Sat May 29 00:21:19 2010 +0200 @@ -2641,6 +2641,9 @@ ArrayValue array = new ArrayValueImpl(); boolean isMagicQuotes = getIniBoolean("magic_quotes_gpc"); + if(_request == null) + return array; + Cookie []cookies = _request.getCookies(); if (cookies != null) { for (int i = 0; i < cookies.length; i++) { |
||||
| Relationships | |||||
| Attached Files: | |||||
| There are no notes attached to this issue. |