diff options
author | Danny Holman <dholman@gymli.org> | 2023-11-08 19:11:12 -0600 |
---|---|---|
committer | Danny Holman <dholman@gymli.org> | 2023-11-08 19:11:12 -0600 |
commit | f78bf72f3196e7786b68c0b649962cf92ceab6a4 (patch) | |
tree | 5db31210cec1d106ac3595aa7fefb5f81fd84891 /server/src/mini-rat.c | |
parent | 516c4ba5c60a8ca67a68b6b3f2278cf178770eed (diff) |
server: print the client ouput in full do not split
Don't split the client output and print line-by-line, just print the
full buffer unmodified. This requires fewer steps and the lines will be
separated anyway.
Signed-off-by: Danny Holman <dholman@gymli.org>
Diffstat (limited to 'server/src/mini-rat.c')
-rw-r--r-- | server/src/mini-rat.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/server/src/mini-rat.c b/server/src/mini-rat.c index 5579201..cdecf7c 100644 --- a/server/src/mini-rat.c +++ b/server/src/mini-rat.c @@ -102,9 +102,7 @@ void run_exec(int sock, const char **argv) { memset(buffer, 0, 4096); read_session(cur_session, buffer, 4096); - char* lines = NULL; - str_split(lines, &buffer, "\r\n"); - dprintf(sock, lines[0]); + dprintf(sock, buffer); free(buffer); } |