Move up state_init()

This commit is contained in:
angt
2016-01-18 17:26:42 +01:00
parent 219384b7e5
commit 2999faf5d7

View File

@@ -1151,6 +1151,9 @@ int main (int argc, char **argv)
if (!ai)
return 1;
if (state_init(statefile))
return 1;
struct fdbuf tun = { .fd = -1 };
struct fdbuf sock = { .fd = -1 };
@@ -1183,9 +1186,6 @@ int main (int argc, char **argv)
if (gt_setup_secretkey(&ctx, keyfile))
return 1;
if (state_init(statefile))
return 1;
long retry = 0;
uint8_t *db = NULL;