diff options
author | Martin Willi <martin@strongswan.org> | 2009-09-11 15:35:10 +0200 |
---|---|---|
committer | Martin Willi <martin@strongswan.org> | 2009-09-11 15:39:35 +0200 |
commit | 3b878dae7e7bb00f8d886426dc4f75bf45b8113f (patch) | |
tree | be56294135f3b29788390b4695de1c973b454302 /scripts/pubkey_speed.c | |
parent | 3a7bd9bd49685c96313038436b770115651b7caa (diff) | |
download | strongswan-3b878dae7e7bb00f8d886426dc4f75bf45b8113f.tar.bz2 strongswan-3b878dae7e7bb00f8d886426dc4f75bf45b8113f.tar.xz |
Removed chunk_from_buf() in favor of a simpler chunk_from_chars() macro
Diffstat (limited to 'scripts/pubkey_speed.c')
-rw-r--r-- | scripts/pubkey_speed.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/scripts/pubkey_speed.c b/scripts/pubkey_speed.c index e6c668832..255f650f5 100644 --- a/scripts/pubkey_speed.c +++ b/scripts/pubkey_speed.c @@ -25,8 +25,6 @@ static void usage() exit(1); } -static char data_buf[] = {0x01,0x02,0x03,0x04,0x05,0x06,0x07}; - int main(int argc, char *argv[]) { private_key_t *private; @@ -36,7 +34,7 @@ int main(int argc, char *argv[]) char buf[8096], *pos = buf; key_type_t type = KEY_ANY; signature_scheme_t scheme = SIGN_UNKNOWN; - chunk_t keydata, *sigs, data = chunk_from_buf(data_buf); + chunk_t keydata, *sigs, data; if (argc < 4) { @@ -102,6 +100,7 @@ int main(int argc, char *argv[]) sigs = malloc(sizeof(chunk_t) * rounds); + data = chunk_from_chars(0x01,0x02,0x03,0x04,0x05,0x06,0x07); start_timing(&timing); for (round = 0; round < rounds; round++) { |