summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordimitri staessens <dimitri.staessens@ugent.be>2017-04-13 12:00:09 +0200
committerdimitri staessens <dimitri.staessens@ugent.be>2017-04-13 12:14:24 +0200
commitb43e8cd0f0858e78486752007c3640b70bf44c8d (patch)
treeb07a8c54f0e2cdcf258fba38ae77edc02e3d17d1 /src
parent72c28d6173ade511e9dc6969e0fc66db2dbba38a (diff)
downloadouroboros-b43e8cd0f0858e78486752007c3640b70bf44c8d.tar.gz
ouroboros-b43e8cd0f0858e78486752007c3640b70bf44c8d.zip
include, lib: Rename ap_init/ap_fini
Fixes #35
Diffstat (limited to 'src')
-rw-r--r--src/ipcpd/ipcp.c8
-rw-r--r--src/irmd/main.c2
-rw-r--r--src/lib/dev.c4
-rw-r--r--src/tools/cbr/cbr.c6
-rw-r--r--src/tools/echo/echo.c6
-rw-r--r--src/tools/echo/echo_server.c2
-rw-r--r--src/tools/operf/operf.c6
-rw-r--r--src/tools/oping/oping.c6
8 files changed, 20 insertions, 20 deletions
diff --git a/src/ipcpd/ipcp.c b/src/ipcpd/ipcp.c
index 795ce42c..47c951f1 100644
--- a/src/ipcpd/ipcp.c
+++ b/src/ipcpd/ipcp.c
@@ -476,12 +476,12 @@ int ipcp_init(int argc,
log_init(log);
if (type == IPCP_NORMAL) {
- if (ap_init(argv[0])) {
+ if (ouroboros_init(argv[0])) {
log_err("Failed to init normal IPCPI.");
return -1;
}
} else {
- if (ap_init(NULL)) {
+ if (ouroboros_init(NULL)) {
log_err("Failed to init shim IPCPI.");
return -1;
}
@@ -600,7 +600,7 @@ int ipcp_init(int argc,
fail_sock_path:
free(ipcpi.threadpool);
fail_thr:
- ap_fini();
+ ouroboros_fini();
return ret;
}
@@ -732,7 +732,7 @@ void ipcp_fini()
log_fini();
- ap_fini();
+ ouroboros_fini();
log_info("IPCP %d out.", getpid());
}
diff --git a/src/irmd/main.c b/src/irmd/main.c
index d24c0ba1..bdc03ef8 100644
--- a/src/irmd/main.c
+++ b/src/irmd/main.c
@@ -931,7 +931,7 @@ static int flow_accept(pid_t api,
e = api_table_get(&irmd.api_table, api);
if (e == NULL) {
- /* Can only happen if server called ap_init(NULL); */
+ /* Can only happen if server called ouroboros_init(NULL); */
pthread_rwlock_unlock(&irmd.reg_lock);
log_err("Unknown instance %d calling accept.", api);
return -EINVAL;
diff --git a/src/lib/dev.c b/src/lib/dev.c
index d68fb471..757f26a8 100644
--- a/src/lib/dev.c
+++ b/src/lib/dev.c
@@ -245,7 +245,7 @@ static void reset_flow(int fd)
init_flow(fd);
}
-int ap_init(const char * ap_name)
+int ouroboros_init(const char * ap_name)
{
int i = 0;
@@ -335,7 +335,7 @@ int ap_init(const char * ap_name)
return 0;
}
-void ap_fini()
+void ouroboros_fini()
{
int i = 0;
diff --git a/src/tools/cbr/cbr.c b/src/tools/cbr/cbr.c
index cd29c9ad..597ae8a6 100644
--- a/src/tools/cbr/cbr.c
+++ b/src/tools/cbr/cbr.c
@@ -129,14 +129,14 @@ int main(int argc, char ** argv)
}
if (server) {
- if (ap_init(argv_dup[0]) < 0) {
+ if (ouroboros_init(argv_dup[0]) < 0) {
printf("Failed to init.\n");
exit(EXIT_FAILURE);
}
ret = server_main();
} else {
- if (ap_init(NULL) < 0) {
+ if (ouroboros_init(NULL) < 0) {
printf("Failed to init.\n");
exit(EXIT_FAILURE);
}
@@ -150,7 +150,7 @@ int main(int argc, char ** argv)
ret = client_main(s_apn, duration, size, rate, flood, sleep);
}
- ap_fini();
+ ouroboros_fini();
return ret;
}
diff --git a/src/tools/echo/echo.c b/src/tools/echo/echo.c
index 051a16c3..b68e8c02 100644
--- a/src/tools/echo/echo.c
+++ b/src/tools/echo/echo.c
@@ -59,20 +59,20 @@ int main(int argc, char ** argv)
}
if (server) {
- if (ap_init(argv_dup[0])) {
+ if (ouroboros_init(argv_dup[0])) {
printf("Failed to init AP.\n");
return -1;
}
ret = server_main();
} else {
- if (ap_init(NULL)) {
+ if (ouroboros_init(NULL)) {
printf("Failed to init AP.\n");
return -1;
}
ret = client_main();
}
- ap_fini();
+ ouroboros_fini();
return ret;
}
diff --git a/src/tools/echo/echo_server.c b/src/tools/echo/echo_server.c
index 771155f4..22175a65 100644
--- a/src/tools/echo/echo_server.c
+++ b/src/tools/echo/echo_server.c
@@ -31,7 +31,7 @@ void shutdown_server(int signo)
{
(void) signo;
- ap_fini();
+ ouroboros_fini();
exit(EXIT_SUCCESS);
}
diff --git a/src/tools/operf/operf.c b/src/tools/operf/operf.c
index 7935d12c..5e7f2f37 100644
--- a/src/tools/operf/operf.c
+++ b/src/tools/operf/operf.c
@@ -140,14 +140,14 @@ int main(int argc, char ** argv)
}
if (serv) {
- if (ap_init(argv_dup[0])) {
+ if (ouroboros_init(argv_dup[0])) {
printf("Failed to init AP.\n");
exit(EXIT_FAILURE);
}
ret = server_main();
} else {
- if (ap_init(NULL)) {
+ if (ouroboros_init(NULL)) {
printf("Failed to init AP.\n");
exit(EXIT_FAILURE);
}
@@ -171,7 +171,7 @@ int main(int argc, char ** argv)
ret = client_main();
}
- ap_fini();
+ ouroboros_fini();
if (ret < 0)
exit(EXIT_FAILURE);
diff --git a/src/tools/oping/oping.c b/src/tools/oping/oping.c
index 7c9c108c..a88e06e5 100644
--- a/src/tools/oping/oping.c
+++ b/src/tools/oping/oping.c
@@ -139,14 +139,14 @@ int main(int argc, char ** argv)
}
if (serv) {
- if (ap_init(argv_dup[0])) {
+ if (ouroboros_init(argv_dup[0])) {
printf("Failed to init AP.\n");
exit(EXIT_FAILURE);
}
ret = server_main();
} else {
- if (ap_init(NULL)) {
+ if (ouroboros_init(NULL)) {
printf("Failed to init AP.\n");
exit(EXIT_FAILURE);
}
@@ -179,7 +179,7 @@ int main(int argc, char ** argv)
ret = client_main();
}
- ap_fini();
+ ouroboros_fini();
if (ret < 0)
exit(EXIT_FAILURE);