Martin Stjernholm, Roxen IS @ Pike developers forum wrote:
the same seems to be happening in the blocking variant do_method_url.
Right, thanks.
There is also a bug in Tools.Hilfe.GenericAsyncHilfe, where the write callback is triggered permanently because an empty string is written in case the outbuffer is empty. I attached a patch for hilfe.
I'm not familiar with that code, but for write callbacks in general, they shouldn't be installed in the first place unless they're going to actually write something. I guess your patch covers the problem since the write callback gets blocked internally until the next write on the fd, but then it could remain blocked even when something is put into the output buffer.
The send_output method which writes to the buffer triggers a write attempt. So that should not be a problem. But I cannot say how it was intended to work in the first place.