Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/checkpoint-restore/criu.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/soccr
diff options
context:
space:
mode:
authorPavel Emelyanov <xemul@virtuozzo.com>2017-04-04 20:45:20 +0300
committerAndrei Vagin <avagin@virtuozzo.com>2017-04-11 08:59:16 +0300
commitfc9fea15af30fc23f97ab9cc94d284644e4402c1 (patch)
treea0de6f88041af24bd05168f19276928c06fa71cb /soccr
parent5a7b90b5957049c6dd2b45e4504bbae72b642e5a (diff)
soccr: Print errors in send_fin (v2)
v2: Use logerr where needed. Signed-off-by: Pavel Emelyanov <xemul@virtuozzo.com> Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
Diffstat (limited to 'soccr')
-rw-r--r--soccr/soccr.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/soccr/soccr.c b/soccr/soccr.c
index 70f99357a..cb3f7b9c1 100644
--- a/soccr/soccr.c
+++ b/soccr/soccr.c
@@ -564,11 +564,15 @@ static int send_fin(struct libsoccr_sk *sk, struct libsoccr_sk_data *data,
libnet_type, /* injection type */
NULL, /* network interface */
errbuf); /* errbuf */
- if (l == NULL)
+ if (l == NULL) {
+ loge("libnet_init failed (%s)\n", errbuf);
return -1;
+ }
- if (setsockopt(l->fd, SOL_SOCKET, SO_MARK, &mark, sizeof(mark)))
+ if (setsockopt(l->fd, SOL_SOCKET, SO_MARK, &mark, sizeof(mark))) {
+ logerr("Can't set SO_MARK (%d) for socket\n", mark);
goto err;
+ }
ret = libnet_build_tcp(
ntohs(sk->dst_addr->v4.sin_port), /* source port */