summaryrefslogtreecommitdiff
path: root/src/g10lib.h
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2017-06-16 10:42:44 +0200
committerWerner Koch <wk@gnupg.org>2017-06-16 10:42:44 +0200
commitb05a4abc358b204dba343d9cfbd59fdc828c1686 (patch)
treecfa7f763b569535f5bf00cdc22292a8694a4fb5e /src/g10lib.h
parentf5e7763ddca59dcd9ac9f2f4d50cb41b14a34a9e (diff)
downloadlibgcrypt-b05a4abc358b204dba343d9cfbd59fdc828c1686.tar.gz
Implement global config file /etc/gcrypt/random.conf
* src/hwfeatures.c (my_isascii): Move macro to ... * src/g10lib.h: here. * tests/random.c (main): Dump random stats. * random/random.c (RANDOM_CONF_FILE): New. (_gcry_random_read_conf): New. (_gcry_random_dump_stats): Call rndjent stats. * random/rndjent.c (jent_rng_totalcalls, jent_rng_totalbytes): New. (_gcry_rndjent_poll): Take care of config option disable-jent. Wipe buffer. Bump counters. (_gcry_rndjent_dump_stats): New. Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'src/g10lib.h')
-rw-r--r--src/g10lib.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/g10lib.h b/src/g10lib.h
index 82562c70..ec8aab56 100644
--- a/src/g10lib.h
+++ b/src/g10lib.h
@@ -96,6 +96,9 @@
#define DIM(v) (sizeof(v)/sizeof((v)[0]))
#define DIMof(type,member) DIM(((type *)0)->member)
+#define my_isascii(c) (!((c) & 0x80))
+
+
/*-- src/global.c -*/