summaryrefslogtreecommitdiff
path: root/ecp/util
diff options
context:
space:
mode:
authorUros Majstorovic <majstor@majstor.org>2022-08-09 21:54:45 +0200
committerUros Majstorovic <majstor@majstor.org>2022-08-09 21:54:45 +0200
commit810dde21ee65653c15606917b19566cfbaaf165e (patch)
tree4cd84b109e06660a9c59f2487822905e5672681e /ecp/util
parentaee853a208d6abec53ec81dc4ef110b63e13342f (diff)
ecp server added
Diffstat (limited to 'ecp/util')
-rw-r--r--ecp/util/mknode.c9
-rw-r--r--ecp/util/util.c2
2 files changed, 7 insertions, 4 deletions
diff --git a/ecp/util/mknode.c b/ecp/util/mknode.c
index 764ac18..bc66da0 100644
--- a/ecp/util/mknode.c
+++ b/ecp/util/mknode.c
@@ -4,7 +4,7 @@
#include <stdio.h>
#include <string.h>
-#include <core.h>
+#include <ecp/core.h>
#include "util.h"
@@ -38,8 +38,11 @@ int main(int argc, char *argv[]) {
rv = ecp_dhkey_gen(&key);
if (rv) goto err;
- rv = ecp_node_init(&node, &key.public, addr);
- if (rv) goto err;
+ ecp_node_init(&node, &key.public, NULL);
+ if (addr) {
+ rv = ecp_node_set_addr(&node, addr);
+ if (rv) goto err;
+ }
rv = ecp_util_save_key(&key.public, &key.private, fn_key);
if (rv) goto err;
diff --git a/ecp/util/util.c b/ecp/util/util.c
index 2b67127..efcf152 100644
--- a/ecp/util/util.c
+++ b/ecp/util/util.c
@@ -3,7 +3,7 @@
#include <unistd.h>
#include <sys/stat.h>
-#include <core.h>
+#include <ecp/core.h>
#include "util.h"