aboutsummaryrefslogtreecommitdiffstats
path: root/src/swanctl/commands/log.c
diff options
context:
space:
mode:
authorMartin Willi <martin@revosec.ch>2014-10-10 11:42:28 +0200
committerMartin Willi <martin@revosec.ch>2014-10-10 11:43:43 +0200
commitef90d5ab1598cd5d81556ddb18845a7d4dc75d8c (patch)
tree4838a830bb5a1e5b9079655a768e3ee6c2f6587c /src/swanctl/commands/log.c
parent05db0f97e3051150a38511fdb35c9d58bb6e989b (diff)
parent7431ad0de54d25c5ac08054972896a48d75f9f70 (diff)
downloadstrongswan-ef90d5ab1598cd5d81556ddb18845a7d4dc75d8c.tar.bz2
strongswan-ef90d5ab1598cd5d81556ddb18845a7d4dc75d8c.tar.xz
Merge branch 'vici-ruby'
Adds a ruby gem for the VICI protocol, along with some documentation improvements and some minor fixes to vici and swanctl.
Diffstat (limited to 'src/swanctl/commands/log.c')
-rw-r--r--src/swanctl/commands/log.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/swanctl/commands/log.c b/src/swanctl/commands/log.c
index 99ba328a7..d7082bfca 100644
--- a/src/swanctl/commands/log.c
+++ b/src/swanctl/commands/log.c
@@ -50,6 +50,7 @@ static int logcmd(vici_conn_t *conn)
{
command_format_options_t format = COMMAND_FORMAT_NONE;
char *arg;
+ int ret;
while (TRUE)
{
@@ -73,8 +74,9 @@ static int logcmd(vici_conn_t *conn)
if (vici_register(conn, "log", log_cb, &format) != 0)
{
+ ret = errno;
fprintf(stderr, "registering for log failed: %s\n", strerror(errno));
- return errno;
+ return ret;
}
wait_sigint();