aboutsummaryrefslogtreecommitdiff
path: root/works/life/computer-network-experiment/server.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'works/life/computer-network-experiment/server.cpp')
-rw-r--r--works/life/computer-network-experiment/server.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/works/life/computer-network-experiment/server.cpp b/works/life/computer-network-experiment/server.cpp
index 14987f3..f12630a 100644
--- a/works/life/computer-network-experiment/server.cpp
+++ b/works/life/computer-network-experiment/server.cpp
@@ -49,7 +49,7 @@ void ResponseThreadProc(int socket, sockaddr_in address) {
byte_count_sent += byte_actually_sent;
}
- SendOutput(CRUT("Succeeded to send message to {}!\n"),
+ SendOutput(OutputColor::Green, CRUT("Succeeded to send message to {}!\n"),
ConvertCharString(address_string));
CloseSocket(socket);
@@ -78,9 +78,10 @@ int Main() {
PrintErrorMessageAndExit(CRUT("Failed to listen."));
}
- while (true) {
- SendOutput(CRUT("Now start to accept incoming connection.\n"));
+ SendOutput(OutputColor::Green,
+ CRUT("Now start to accept incoming connection.\n"));
+ while (true) {
sockaddr_in client_address;
int client_socket;
unsigned sin_size = sizeof(sockaddr_in);