mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
more bug fixesand some warning cleanups
This commit is contained in:
parent
2874670be9
commit
d4cd7a3d4b
23 changed files with 164 additions and 61 deletions
|
@ -1,3 +1,7 @@
|
|||
2001-09-09 Werner Koch <wk@gnupg.org>
|
||||
|
||||
* rsa.c (rsa_get_info): s/usage/r_usage/ to avoid shadow warnings.
|
||||
|
||||
2001-08-24 Werner Koch <wk@gnupg.org>
|
||||
|
||||
* md.c (md_write): Made buf arg const.
|
||||
|
|
|
@ -296,7 +296,7 @@ set_random_seed_file( const char *name )
|
|||
* and return true if this was successful
|
||||
*/
|
||||
static int
|
||||
read_seed_file()
|
||||
read_seed_file(void)
|
||||
{
|
||||
int fd;
|
||||
struct stat sb;
|
||||
|
|
12
cipher/rsa.c
12
cipher/rsa.c
|
@ -446,7 +446,7 @@ rsa_get_nbits( int algo, MPI *pkey )
|
|||
*/
|
||||
const char *
|
||||
rsa_get_info( int algo,
|
||||
int *npkey, int *nskey, int *nenc, int *nsig, int *usage )
|
||||
int *npkey, int *nskey, int *nenc, int *nsig, int *r_usage )
|
||||
{
|
||||
*npkey = 2;
|
||||
*nskey = 6;
|
||||
|
@ -454,10 +454,12 @@ rsa_get_info( int algo,
|
|||
*nsig = 1;
|
||||
|
||||
switch( algo ) {
|
||||
case 1: *usage = PUBKEY_USAGE_SIG | PUBKEY_USAGE_ENC; return "RSA";
|
||||
case 2: *usage = PUBKEY_USAGE_ENC; return "RSA-E";
|
||||
case 3: *usage = PUBKEY_USAGE_SIG; return "RSA-S";
|
||||
default:*usage = 0; return NULL;
|
||||
case 1: *r_usage = PUBKEY_USAGE_SIG | PUBKEY_USAGE_ENC; return "RSA";
|
||||
case 2: *r_usage = PUBKEY_USAGE_ENC; return "RSA-E";
|
||||
case 3: *r_usage = PUBKEY_USAGE_SIG; return "RSA-S";
|
||||
default:*r_usage = 0; return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue