aboutsummaryrefslogtreecommitdiff
path: root/tests/unittests/torture_keyfiles.c
diff options
context:
space:
mode:
authorAris Adamantiadis <aris@0xbadc0de.be>2010-05-14 00:51:08 +0200
committerAris Adamantiadis <aris@0xbadc0de.be>2010-05-14 00:51:08 +0200
commitb23b3f1d9951df3ea7cc074de40db04bdf0d3a1c (patch)
treed4fe8f4c4aa71c6cebe7d1d92dc25ea145d98cd1 /tests/unittests/torture_keyfiles.c
parent46b249f5ce552bba2e0a170cb0b8052b1419924b (diff)
downloadlibssh-b23b3f1d9951df3ea7cc074de40db04bdf0d3a1c.tar.gz
libssh-b23b3f1d9951df3ea7cc074de40db04bdf0d3a1c.tar.xz
libssh-b23b3f1d9951df3ea7cc074de40db04bdf0d3a1c.zip
Sanitize libssh namespace + legacy wrappers
Diffstat (limited to 'tests/unittests/torture_keyfiles.c')
-rw-r--r--tests/unittests/torture_keyfiles.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/unittests/torture_keyfiles.c b/tests/unittests/torture_keyfiles.c
index 653bebab..7f57b5bf 100644
--- a/tests/unittests/torture_keyfiles.c
+++ b/tests/unittests/torture_keyfiles.c
@@ -64,7 +64,7 @@ START_TEST (torture_pubkey_from_file)
ck_assert_msg(rc == 0,ssh_get_error(session));
- string_free(pubkey);
+ ssh_string_free(pubkey);
/* test if it returns 1 if pubkey doesn't exist */
unlink(LIBSSH_RSA_TESTKEY ".pub");
@@ -138,9 +138,9 @@ START_TEST (torture_pubkey_generate_from_privkey)
ck_assert_msg(pubkey_new != NULL,ssh_get_error(session));
- ck_assert(string_len(pubkey_orig) == string_len(pubkey_new));
- ck_assert(memcmp(string_data(pubkey_orig), string_data(pubkey_new),
- string_len(pubkey_orig)) == 0);
+ ck_assert(ssh_string_len(pubkey_orig) == ssh_string_len(pubkey_new));
+ ck_assert(memcmp(ssh_string_data(pubkey_orig), ssh_string_data(pubkey_new),
+ ssh_string_len(pubkey_orig)) == 0);
rc = ssh_publickey_to_file(session, LIBSSH_RSA_TESTKEY ".pub", pubkey_new, type_new);
ck_assert_msg(rc == 0,ssh_get_error(session));
@@ -150,8 +150,8 @@ START_TEST (torture_pubkey_generate_from_privkey)
ck_assert_str_eq(pubkey_line_orig, pubkey_line_new);
- string_free(pubkey_orig);
- string_free(pubkey_new);
+ ssh_string_free(pubkey_orig);
+ ssh_string_free(pubkey_new);
}
END_TEST