Jump to content

Recommended Posts

Hi,

 

I\'ve just installed Apache 2.0.47 and finally got it working. :) Much quicker than IIS, by the way, which I\'ve now disabled. However, when I test out some links on my web pages, I get a strange problem. I get a dialog box message saying:

 

The instruction at \"0x77c42e0a\" reference memory at \"0x00000000\". The memory could not be \"read\".

 

The title of the dialog box is: Apache.exe - Application Error

 

I\'ve tracked the problem down by trial and error to the fact that when there is an url parameter on the link without a value (e.g. ?parm=), then this problem happens and a \"page cannot be displayed\" page is displayed. It doesn\'t matter where in the set of parameters it occurs, just that it exists without a value. When it has a value, the link works fine and the next page is displayed.

 

Does anyone have an idea what may be causing it and how to solve the problem as I\'m getting very frustrated and have run out of ideas to try.

 

Thanks if anyone can help.

 

Debbie-Leigh

Link to comment
https://forums.phpfreaks.com/topic/979-memory-could-not-be-read-problem/
Share on other sites

  • 3 weeks later...

Hi,

 

I\'ve finally found the solution to this little problem and thought I\'d share it with everyone.

 

It turns out not to be an Apache problem, but what appears to be a bug in PHP. I had created a little subroutine to encode any text parameters before putting them into urls. Part of that routine uses the PHP function: html_entity_decode, which, it seems, cannot handle an empty string being passed to it. If it does encounter an empty string, then it seems to start behaving very badly and causes the problems outlined in my original post.

 

So, my solution was to test the passed string before using html_entity_decode and, if it is empty, then just pass it back as is.

 

What would be a perfect solution, though, is for this routine to be fixed, so I\'ll be passing this on to the PHP bods.

 

Hopes this helps.

 

Debbie-Leigh

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.