finish rq to work with current format; add to makefile

This commit is contained in:
Andy2 2010-09-21 06:26:49 -07:00
parent 4ad735124c
commit 2ec67c8ed1
2 changed files with 3 additions and 3 deletions

View file

@ -55,7 +55,7 @@ xwrelay: $(OBJ)
rq: rq.c
clean:
rm -f xwrelay $(OBJ)
rm -f xwrelay $(OBJ) rq
tags:
etags *.cpp *.h

View file

@ -70,7 +70,7 @@ do_rooms( int sockfd, int lang, int nPlayers )
write( sockfd, &len, sizeof(len) );
write( sockfd, msg, sizeof(msg) );
fprintf( stderr, "Waiting for response...." );
fprintf( stderr, "Waiting for response....\n" );
ssize_t nRead = recv( sockfd, &len,
sizeof(len), MSG_WAITALL );
assert( nRead == sizeof(len) );
@ -89,7 +89,7 @@ do_rooms( int sockfd, int lang, int nPlayers )
char* saveptr;
for ( ii = 0; ii < nRooms; ++ii ) {
char* str = strtok_r( ptr, "\n", &saveptr );
fprintf( stdout, "%s", str );
fprintf( stdout, "%s\n", str );
ptr = NULL;
}
}