[Cryptech-Commits] [sw/libhal] 01/04: Add hal_rpc_client_close() where needed.

git at cryptech.is git at cryptech.is
Fri Jun 3 08:54:29 UTC 2016


This is an automated email from the git hooks/post-receive script.

paul at psgd.org pushed a commit to branch master
in repository sw/libhal.

commit b83f77f5517d65c11052ab11e48b56dcb9f712ef
Author: Paul Selkirk <paul at psgd.org>
AuthorDate: Wed Jun 1 16:43:20 2016 -0400

    Add hal_rpc_client_close() where needed.
---
 tests/test-rpc_get_random.c  | 1 +
 tests/test-rpc_get_version.c | 1 +
 tests/test-rpc_pkey.c        | 2 ++
 tests/test-rpc_server.c      | 1 +
 4 files changed, 5 insertions(+)

diff --git a/tests/test-rpc_get_random.c b/tests/test-rpc_get_random.c
index e495514..ad0c6e8 100644
--- a/tests/test-rpc_get_random.c
+++ b/tests/test-rpc_get_random.c
@@ -65,5 +65,6 @@ int main(int argc, char *argv[])
 
     hexdump(rnd, len);
 
+    check(hal_rpc_client_close());
     return 0;
 }
diff --git a/tests/test-rpc_get_version.c b/tests/test-rpc_get_version.c
index d9041b8..b46dc64 100644
--- a/tests/test-rpc_get_version.c
+++ b/tests/test-rpc_get_version.c
@@ -47,5 +47,6 @@ int main(int argc, char *argv[])
     check(hal_rpc_get_version(&version));
     printf("%08x\n", version);
 
+    check(hal_rpc_client_close());
     return 0;
 }
diff --git a/tests/test-rpc_pkey.c b/tests/test-rpc_pkey.c
index f5374b3..f6b6f15 100644
--- a/tests/test-rpc_pkey.c
+++ b/tests/test-rpc_pkey.c
@@ -334,6 +334,8 @@ int main (int argc, char *argv[])
   for (int i = 0; i < (sizeof(ecdsa_tc)/sizeof(*ecdsa_tc)); i++)
     ok &= test_ecdsa_generate(&ecdsa_tc[i]);
 
+  ok &= hal_rpc_client_close();
+
   return !ok;
 }
 
diff --git a/tests/test-rpc_server.c b/tests/test-rpc_server.c
index eb11f6d..b0b2fd0 100644
--- a/tests/test-rpc_server.c
+++ b/tests/test-rpc_server.c
@@ -6,5 +6,6 @@ int main (int argc, char *argv[])
 	return 1;
 
     hal_rpc_server_main();
+    hal_rpc_server_close();
     return 0;
 }



More information about the Commits mailing list