Hello, I think this is the only possible way to do it... (without rewriting the whole extension).
Derick On 17 Jan 2002, Robin Ericsson wrote: > Using this fix, it works for me, but I don't know if this is the right > way to go.. > > diff -u -u -r1.21 shmop.c > --- shmop.c 9 Jan 2002 08:02:21 -0000 1.21 > +++ shmop.c 17 Jan 2002 10:11:02 -0000 > @@ -242,8 +242,9 @@ > startaddr = shmop->addr + (*start)->value.lval; > bytes = (*count)->value.lval ? (*count)->value.lval : > shmop->size-(*start)->value.lval; > > - return_string = emalloc(bytes); > + return_string = emalloc(bytes+1); > memcpy(return_string, startaddr, bytes); > + return_string[bytes] = '\0'; > > RETURN_STRINGL(return_string, bytes, 0); > } > > > > > > -- > PHP Development Mailing List <http://www.php.net/> > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED] > -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]