This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Cygwin/DOS pipes, TCP/IP


Hi,

I'm trying to download a page until an expression (server
doesn't accept ranges):

curl -N url | sed -u "/expression/q" > file

Sed finds the expression, then exits, breaks pipe, interrupts curl (it
produces a writing error message), the file contains expected result. Nice,
but it
downloads much more bytes than the file size.

I force unbuffered behaviour, but I work on a Cygwin/DOS
enviroment, I'm afraid that programs are not concurrent, so DOS would buffer
information before swaping. Am I right? BTW, anyone can give me some links
with internal
information of filter pipes on DOS/Windows?

Could it be a net protocol side-effect? Anything relative to the minimum
size
of every package? In university I learnt that net protocols use transference
window, I mean, client requests several message parts at the same time, not
sequentially. Perhaps curl (or a lower layer) receives information that it
doesn't read yet. The socket is closed, then must I pay all the other
packages?. Is there a way to modify the package, window size in TCP/IP?

You can propose me alternative ways to do the same task, of course.

Thanks a lot.


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]