projects
/
gapil.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Ancora message queues
[gapil.git]
/
sources
/
ElemEchoTCPClient.c
diff --git
a/sources/ElemEchoTCPClient.c
b/sources/ElemEchoTCPClient.c
index 57b8fa1e3a94bcee4018ac14ddb92cf3afee2444..3529cd792203a3d5348bab470a79f6c50cd4926c 100644
(file)
--- a/
sources/ElemEchoTCPClient.c
+++ b/
sources/ElemEchoTCPClient.c
@@
-26,7
+26,7
@@
*
* Usage: echo -h give all info's
*
*
* Usage: echo -h give all info's
*
- * $Id: ElemEchoTCPClient.c,v 1.
3 2001/09/09 22:45:34
piccardi Exp $
+ * $Id: ElemEchoTCPClient.c,v 1.
5 2003/02/02 20:35:33
piccardi Exp $
*
****************************************************************/
/*
*
****************************************************************/
/*
@@
-38,8
+38,6
@@
#include <sys/socket.h> /* socket library */
#include <stdio.h> /* include standard I/O library */
#include <sys/socket.h> /* socket library */
#include <stdio.h> /* include standard I/O library */
-#include "wrappers.h"
-
#define MAXLINE 256
void usage(void);
void ClientEcho(FILE * filein, int socket);
#define MAXLINE 256
void usage(void);
void ClientEcho(FILE * filein, int socket);
@@
-122,8
+120,8
@@
void ClientEcho(FILE * filein, int socket)
char sendbuff[MAXLINE], recvbuff[MAXLINE];
int nread;
while (fgets(sendbuff, MAXLINE, filein) != NULL) {
char sendbuff[MAXLINE], recvbuff[MAXLINE];
int nread;
while (fgets(sendbuff, MAXLINE, filein) != NULL) {
-
Sock
Write(socket, sendbuff, strlen(sendbuff));
- nread =
Sock
Read(socket, recvbuff, strlen(sendbuff));
+
Full
Write(socket, sendbuff, strlen(sendbuff));
+ nread =
Full
Read(socket, recvbuff, strlen(sendbuff));
recvbuff[nread] = 0;
fputs(recvbuff, stdout);
}
recvbuff[nread] = 0;
fputs(recvbuff, stdout);
}