> |Body-Filter: C:\cygwin\bin\sed.exe "s/script/deleted"
> The command should be as "/script/d" to be acceptable by sed, if your
> intention is to "delete lines including the string 'script'".
> And you can use the internal builtin sed (-sed) for commands when the
> matching pattern is simple like:
> Body-Filter: -sed "/to be deleted/d"
No, I wanted to replace 'script' with 'deleted' in the html body but I
forgot the '/' at the end (only in my email). The correct line:
Body-Filter: C:\cygwin\bin\sed.exe "s/script/deleted/"
This -sed option is not in the manual! But it works great! You should update
the documentation! :)
Of course I don't want to use external programs to filter the body part of
the html response, I just haven't found a better solution.
This built-in sed has the same functionality as the unix command sed has?
The best solution would be, if any kind of regular expressions could be used
to replace strings in incoming-outgoing streams. Is there any chance to
implement this sometime?
work when only a simple <script> was in the body (it was killed if it was
<script >) Is this a bug or a feature? :)
> I think you must have seen lines around here like
> "#### ERROR: select() appllied to non-SOCKET handle"
> |06/29 14:45:27.01  0+0: simple_relay [27 -> 5] = (0 -> 0) / 0
> |(WIN) 45:27  wait(0) = ...
> If so, it shows the reason of the error.
Yes, I see those error lines.
> A filter program is connected to/from DeleGate with PIPE instead of
> since usual programs on Windows do not understand a socket as a
> standard input/output. But on Windows, pipe cannot be treated like socket
> to be polled with select(X-<). Here select() is used in simple_relay()
> when an input to a filter is relayed by DeleGate, and when the input (body
> of a HTTP message) is buffered in a stream buffer (prefetched together
> on reading the HTTP header). Thus the above problem occur.
> I did the simplest solution for this problem like the patch enclosed, in
> 9.0.3-pre27. I know it makes the CFIscript on Windows slower because it
> read() for each byte in a HTTP header, but anyway it makes
> work. The patched version is availabe at
> I will support ICAP in 9.0.X and extend or replace a part of CFI with it,
> thus problems depending on local pipe() like this might be solved in the
> new scheme.
Thank you for your response and help! Best regards,