summaryrefslogtreecommitdiffstats
path: root/g10/gpg.h
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2015-11-14 09:13:02 +0100
committerWerner Koch <wk@gnupg.org>2015-11-14 09:13:02 +0100
commit3689c2105aab6a4304e9464c5b20207d69b9a133 (patch)
tree9b6b205a05ed03edfe72f89983e55cf52d7222fc /g10/gpg.h
parentgpg: Simplify the tofu interface by using the public key packet. (diff)
downloadgnupg2-3689c2105aab6a4304e9464c5b20207d69b9a133.tar.xz
gnupg2-3689c2105aab6a4304e9464c5b20207d69b9a133.zip
gpg: Use only one fingerprint formatting function.
* g10/gpg.h (MAX_FORMATTED_FINGERPRINT_LEN): New. * g10/keyid.c (hexfingerprint): Add optional args BUFFER and BUFLEN. Change all callers. (format_hexfingerprint): New. * g10/keylist.c (print_fingerprint): Change to use hexfingerprint. * g10/tofu.c (fingerprint_format): Remove. Replace calls by format_hexfingerprint. Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'g10/gpg.h')
-rw-r--r--g10/gpg.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/g10/gpg.h b/g10/gpg.h
index 6f92abdde..5cd836697 100644
--- a/g10/gpg.h
+++ b/g10/gpg.h
@@ -43,6 +43,10 @@
Warning: At some places we still use 20 instead of this macro. */
#define MAX_FINGERPRINT_LEN 20
+/* The maximum length of a formatted fingerprint as returned by
+ format_hexfingerprint(). */
+#define MAX_FORMATTED_FINGERPRINT_LEN 50
+
/*
Forward declarations.