diff options
author | Werner Koch <[email protected]> | 2006-05-23 16:19:43 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2006-05-23 16:19:43 +0000 |
commit | fbe4ac37f6d3e7870e26caffb0d21c3c77198297 (patch) | |
tree | f21028be87bda6df4f2f1e3ae105feeb5a2eb158 /g10/misc.c | |
parent | 2006-05-19 Marcus Brinkmann <[email protected]> (diff) | |
download | gnupg-fbe4ac37f6d3e7870e26caffb0d21c3c77198297.tar.gz gnupg-fbe4ac37f6d3e7870e26caffb0d21c3c77198297.zip |
g10/ does build again.
Diffstat (limited to '')
-rw-r--r-- | g10/misc.c | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/g10/misc.c b/g10/misc.c index a26aa740d..12aa6c689 100644 --- a/g10/misc.c +++ b/g10/misc.c @@ -67,6 +67,18 @@ #include "i18n.h" +static int +string_count_chr (const char *string, int c) +{ + int count; + + for (count=0; *string; string++ ) + if ( *string == c ) + count++; + return count; +} + + #ifdef ENABLE_SELINUX_HACKS /* A object and a global variable to keep track of files marked as @@ -416,12 +428,17 @@ openpgp_pk_test_algo( int algo ) int openpgp_pk_test_algo2( int algo, unsigned int use ) { + int use_buf = use; + size_t sizeof_use_buf = sizeof (use_buf); + if (algo == GCRY_PK_ELG_E) algo = GCRY_PK_ELG; if (algo < 0 || algo > 110) return gpg_error (GPG_ERR_PUBKEY_ALGO); - return gcry_pk_test_algo2 (algo, use); + + return gcry_pk_algo_info (algo, GCRYCTL_TEST_ALGO, + &use_buf, &sizeof_use_buf); } int |