mirror of
git://git.gnupg.org/gnupg.git
synced 2024-12-21 10:09:57 +01:00
gpg,common,scd,sm: Function prototype fixes for modern compiler.
* common/gettime.c (gnupg_get_time): It has no arguments. * common/signal.c (gnupg_block_all_signals): Likewise. (gnupg_unblock_all_signals): Likewise. * common/utf8conv.c (get_native_charset): Likewise. * g10/cpr.c (is_status_enabled, cpr_enabled): Likewise. * g10/getkey.c (getkey_disable_caches): Likewise. * g10/keygen.c (ask_expiredate): Likewise. * g10/passphrase.c (have_static_passphrase): Likewise. (get_last_passphrase): Likewise. * g10/tdbio.c (tdbio_is_dirty, tdbio_sync): Likewise. (tdbio_get_dbname, open_db, tdbio_db_matches_options): Likewise. (tdbio_read_nextcheck): Likewise. * g10/trustdb.c (how_to_fix_the_trustdb): Likewise. * scd/scdaemon.c (scd_get_socket_name): Likewise. * sm/passphrase.c (have_static_passphrase): Likewise. -- Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
parent
a47b3a4087
commit
87d4338ed1
@ -64,7 +64,7 @@ static enum { NORMAL = 0, FROZEN, FUTURE, PAST } timemode;
|
||||
/* Wrapper for the time(3). We use this here so we can fake the time
|
||||
for tests */
|
||||
time_t
|
||||
gnupg_get_time ()
|
||||
gnupg_get_time (void)
|
||||
{
|
||||
time_t current = time (NULL);
|
||||
if (current == (time_t)(-1))
|
||||
|
@ -239,13 +239,13 @@ do_block (int block)
|
||||
|
||||
|
||||
void
|
||||
gnupg_block_all_signals ()
|
||||
gnupg_block_all_signals (void)
|
||||
{
|
||||
do_block(1);
|
||||
}
|
||||
|
||||
void
|
||||
gnupg_unblock_all_signals ()
|
||||
gnupg_unblock_all_signals (void)
|
||||
{
|
||||
do_block(0);
|
||||
}
|
||||
|
@ -299,7 +299,7 @@ set_native_charset (const char *newset)
|
||||
}
|
||||
|
||||
const char *
|
||||
get_native_charset ()
|
||||
get_native_charset (void)
|
||||
{
|
||||
return active_charset_name;
|
||||
}
|
||||
|
@ -128,7 +128,7 @@ set_status_fd (int fd)
|
||||
|
||||
|
||||
int
|
||||
is_status_enabled ()
|
||||
is_status_enabled (void)
|
||||
{
|
||||
return !!statusfp;
|
||||
}
|
||||
@ -532,7 +532,7 @@ do_get_from_fd ( const char *keyword, int hidden, int getbool )
|
||||
|
||||
|
||||
int
|
||||
cpr_enabled()
|
||||
cpr_enabled(void)
|
||||
{
|
||||
if( opt.command_fd != -1 )
|
||||
return 1;
|
||||
|
@ -260,7 +260,7 @@ user_id_not_found_utf8 (void)
|
||||
cache_public_key and get_pubkey). Note: there is currently no way
|
||||
to re-enable this cache. */
|
||||
void
|
||||
getkey_disable_caches ()
|
||||
getkey_disable_caches (void)
|
||||
{
|
||||
#if MAX_PK_CACHE_ENTRIES
|
||||
{
|
||||
|
@ -2922,7 +2922,7 @@ ask_expire_interval(int object,const char *def_expire)
|
||||
}
|
||||
|
||||
u32
|
||||
ask_expiredate()
|
||||
ask_expiredate (void)
|
||||
{
|
||||
u32 x = ask_expire_interval(0,NULL);
|
||||
return x? make_timestamp() + x : 0;
|
||||
|
@ -49,7 +49,7 @@ static char *last_pw = NULL;
|
||||
|
||||
|
||||
int
|
||||
have_static_passphrase()
|
||||
have_static_passphrase (void)
|
||||
{
|
||||
return (!!fd_passwd
|
||||
&& (opt.batch || opt.pinentry_mode == PINENTRY_MODE_LOOPBACK));
|
||||
@ -89,7 +89,7 @@ set_next_passphrase( const char *s )
|
||||
* the caller must free the result. May return NULL:
|
||||
*/
|
||||
char *
|
||||
get_last_passphrase()
|
||||
get_last_passphrase (void)
|
||||
{
|
||||
char *p = last_pw;
|
||||
last_pw = NULL;
|
||||
|
12
g10/tdbio.c
12
g10/tdbio.c
@ -415,7 +415,7 @@ put_record_into_cache (ulong recno, const char *data)
|
||||
|
||||
/* Return true if the cache is dirty. */
|
||||
int
|
||||
tdbio_is_dirty()
|
||||
tdbio_is_dirty (void)
|
||||
{
|
||||
return cache_is_dirty;
|
||||
}
|
||||
@ -425,7 +425,7 @@ tdbio_is_dirty()
|
||||
* Flush the cache. This cannot be used while in a transaction.
|
||||
*/
|
||||
int
|
||||
tdbio_sync()
|
||||
tdbio_sync (void)
|
||||
{
|
||||
CACHE_CTRL r;
|
||||
int did_lock = 0;
|
||||
@ -765,7 +765,7 @@ tdbio_set_dbname (ctrl_t ctrl, const char *new_dbname,
|
||||
* Return the full name of the trustdb.
|
||||
*/
|
||||
const char *
|
||||
tdbio_get_dbname ()
|
||||
tdbio_get_dbname (void)
|
||||
{
|
||||
return db_name;
|
||||
}
|
||||
@ -777,7 +777,7 @@ tdbio_get_dbname ()
|
||||
* the trustdb handle (DB_FD) is guaranteed to be open.
|
||||
*/
|
||||
static void
|
||||
open_db ()
|
||||
open_db (void)
|
||||
{
|
||||
TRUSTREC rec;
|
||||
|
||||
@ -859,7 +859,7 @@ create_hashtable (ctrl_t ctrl, TRUSTREC *vr, int type)
|
||||
* Return: 1 for yes, 0 for no.
|
||||
*/
|
||||
int
|
||||
tdbio_db_matches_options()
|
||||
tdbio_db_matches_options (void)
|
||||
{
|
||||
static int yes_no = -1;
|
||||
|
||||
@ -916,7 +916,7 @@ tdbio_read_model (void)
|
||||
* problem the process is terminated.
|
||||
*/
|
||||
ulong
|
||||
tdbio_read_nextcheck ()
|
||||
tdbio_read_nextcheck (void)
|
||||
{
|
||||
TRUSTREC vr;
|
||||
int rc;
|
||||
|
@ -544,7 +544,7 @@ setup_trustdb( int level, const char *dbname )
|
||||
}
|
||||
|
||||
void
|
||||
how_to_fix_the_trustdb ()
|
||||
how_to_fix_the_trustdb (void)
|
||||
{
|
||||
const char *name = trustdb_args.dbname;
|
||||
|
||||
|
@ -998,7 +998,7 @@ scd_deinit_default_ctrl (ctrl_t ctrl)
|
||||
/* Return the name of the socket to be used to connect to this
|
||||
process. If no socket is available, return NULL. */
|
||||
const char *
|
||||
scd_get_socket_name ()
|
||||
scd_get_socket_name (void)
|
||||
{
|
||||
if (socket_name && *socket_name)
|
||||
return socket_name;
|
||||
|
@ -29,7 +29,7 @@
|
||||
static char *fd_passwd = NULL;
|
||||
|
||||
int
|
||||
have_static_passphrase ()
|
||||
have_static_passphrase (void)
|
||||
{
|
||||
return (!!fd_passwd
|
||||
&& (opt.batch || opt.pinentry_mode == PINENTRY_MODE_LOOPBACK));
|
||||
|
Loading…
x
Reference in New Issue
Block a user