aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/client.c
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2022-08-26 07:15:03 +0200
committerEgor Tensin <Egor.Tensin@gmail.com>2022-08-26 07:15:45 +0200
commit93b8646855353ab3adfe5fea8ccb5b0842ad8a0d (patch)
treec87ac95cd819f654d60e360f84a5559faa7de9fe /src/client.c
parentfix macros (diff)
downloadcimple-93b8646855353ab3adfe5fea8ccb5b0842ad8a0d.tar.gz
cimple-93b8646855353ab3adfe5fea8ccb5b0842ad8a0d.zip
add check_errno macro
Diffstat (limited to 'src/client.c')
-rw-r--r--src/client.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/client.c b/src/client.c
index e42019c..be46ad1 100644
--- a/src/client.c
+++ b/src/client.c
@@ -1,4 +1,5 @@
#include "client.h"
+#include "log.h"
#include "msg.h"
#include "net.h"
@@ -15,7 +16,7 @@ int client_create(struct client *client, const struct settings *settings)
void client_destroy(const struct client *client)
{
- close(client->fd);
+ check_errno(close(client->fd), "close");
}
int client_main(const struct client *client, int argc, char *argv[])