in reply to Re: Re: more zero byte madness
in thread more zero byte madness
If you want to be doubly certain it's not your client and it's not your network, use something like ngrep to verify the contents of the message. Verify that the entire command is in the message and that it is terminated with a null byte. I cannot imagine that this is not the case.
On the server side, be sure you aren't doing something like while (<$client>) { ... } (without setting $/). Since you're dealing with a binary protocol, it's better in my experience that you use something like sysread to read data, and subsequently chop that data up into discrete commands. You may also have success setting $/ to "\0" and try reading "lines" like above.
If this is a buffering issue, though, I don't know why the server would see \0 but would not see the contents of the command. That just doesn't make any sense to me. With the information you've given us, I don't see how that is possible. Something isn't right.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Re: more zero byte madness
by chorg (Monk) on Dec 05, 2000 at 23:15 UTC | |
by extremely (Priest) on Dec 06, 2000 at 03:43 UTC |