Re: Connecting Fortran code to TCP/IP socket
- From: Den7 <rrr7rrr@xxxxxxxxx>
- Date: Mon, 28 Sep 2009 20:42:59 -0700 (PDT)
On Sep 28, 5:31 am, feenberg <feenb...@xxxxxxxxx> wrote:
On Sep 28, 7:04 am, Den7 <rrr7...@xxxxxxxxx> wrote:> 1) I am wondering how to make Fortran program communicate with the
server via streaming TCP/IP socket connection.
...
If you invoke your program with the netcat command the standard input
will be drawn from a socket, and its standard output can be sent to a
socket. It is all very easy.
nc host.example.com port -e command
Runs "command" with the standard output going to host.example.com:port
and the standard input coming back from that server. For some time I
was using this, but found that if the command did too much input and
output, the process would eventually hang. If the transfer was mostly
in one direction, there was no problem. There are several newer
implementaions of netcat now, perhaps one or more of them has overcome
this problem. Or perhaps it had to do with the sever. In any case, you
asked for no more than 20 lines - here it is in 1 line!
Note that many implementations of netcat have other names and some do
not implement the -e option.
Daniel Feenberg
feenb...@xxxxxxxx
Thanks, the idea sounds cool.
Couldn't find netcat for latest Windows OS though, all are older
builds for Win 95/98/NT
and of course for Linux...
.
- Follow-Ups:
- Re: Connecting Fortran code to TCP/IP socket
- From: feenberg
- Re: Connecting Fortran code to TCP/IP socket
- References:
- Connecting Fortran code to TCP/IP socket
- From: Den7
- Re: Connecting Fortran code to TCP/IP socket
- From: feenberg
- Connecting Fortran code to TCP/IP socket
- Prev by Date: ▲▲▲Discount Chanel Bracelet Coach Chain Bracelet TOUS Necklace Dior Necklace Juicy Necklace<www.dotradenow.com>
- Next by Date: Passing array slices to subroutines
- Previous by thread: Re: Connecting Fortran code to TCP/IP socket
- Next by thread: Re: Connecting Fortran code to TCP/IP socket
- Index(es):
Relevant Pages
|
Loading