Re: PHP Source Code Help
| From: | Usman S. Ansari | Date: | Mon, 16 Jul 2007 06:48:38 +0000 |
| Subject: | Re: PHP Source Code Help | ||
| References: | 1 2 3 4 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-30956@lists.php.net to get a copy of this message | ||
I tried running apache -X under gdb, problem was system (prime client) timeout out. I am trying to run SPECweb, I suppose most of the people on the list are fimiliar with it.
Anyway I was able to read the code and figure out function called by (wrapper->wops->stream_opener), through layers of buffering and function calling. My TCP stack is returning one bytes less from the start, so http:// 200 is ttp:// 200.
May be it is calling pread to read the data or aio_read (something which is not implemented in my stack), Is there a documentation which can help me understand the code flow with less pain ?
Usman
Alexey Zakhlestin wrote:
start "apache -X" inside of gdb On 7/15/07, Usman S. Ansari <uansari@yahoo.com> wrote:Use any of the debuggers available to step into it and see which function is called.failed to open stream Which I have traced to file: php-4.4.7/main/streams.c and function _php_stream_open_wrapper_exstream = wrapper->wops->stream_opener(wrapper, path_to_open,mode, options ^ REPORT_ERRORS,opened_path, context STREAMS_REL_CC TSRMLS_CC);Error condition occurs when stream is assigned NULL from wrapper->wops->stream_opener call (see above line). I need some help figuring out which function is call by pointer wrapper->wops->stream_opener.Since PHP is called by apache and error happens right away, is there an easy way to invoke php under gdb ? -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php