summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2019-07-26 15:11:17 +0200
committerJo-Philipp Wich <jo@mein.io>2019-07-26 15:11:17 +0200
commit16f23de9779908850f756d62c2550b354c97e0f7 (patch)
treefa40ac6dd39d72751b54c455d3264067d91224f2
parent2a1a60740ab5cd2970267a97142a953452b5d12b (diff)
luci-lib-nixio: fix compilation
Fixes: #2921 Fixes: f3f42ff09 ("address: Replace ualarm with setitimer") Signed-off-by: Jo-Philipp Wich <jo@mein.io>
-rw-r--r--libs/luci-lib-nixio/src/address.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/luci-lib-nixio/src/address.c b/libs/luci-lib-nixio/src/address.c
index ed3a4a1c6..7957e8cc1 100644
--- a/libs/luci-lib-nixio/src/address.c
+++ b/libs/luci-lib-nixio/src/address.c
@@ -288,9 +288,9 @@ static int nixio_getnameinfo(lua_State *L) {
const char *family = luaL_optstring(L, 2, NULL);
#ifdef __linux__
- const struct itimerval t = { {timeout * 1000 * 1000, 0} , {0, 0} };
struct sigaction sa_new, sa_old;
int timeout = luaL_optnumber(L, 3, 0);
+ const struct itimerval t = { {timeout * 1000 * 1000, 0} , {0, 0} };
if (timeout > 0 && timeout < 1000)
{
sa_new.sa_handler = nixio__handle_alarm;