aboutsummaryrefslogtreecommitdiffstats
path: root/common/stringhelp.h
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2016-08-11 18:46:51 +0000
committerWerner Koch <[email protected]>2016-08-11 19:32:55 +0000
commit0698324cde3e0cef7eeb6cfd1640c5eefdf13698 (patch)
tree36a20b69d270381daee74443a17a4108fb407090 /common/stringhelp.h
parentcommon: Remove compatibility code. (diff)
downloadgnupg-0698324cde3e0cef7eeb6cfd1640c5eefdf13698.tar.gz
gnupg-0698324cde3e0cef7eeb6cfd1640c5eefdf13698.zip
common: New function string_to_u64.
* common/stringhelp.c (string_to_u64): New. * dirmngr/http.c (longcounter_t): Remove. (struct cookie_s): Change content_length to uint64_t. (parse_response): Use string_to_u64. -- Meanwhile we allow some C99 features including stdint.h. Thus we can simplify things now. Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to 'common/stringhelp.h')
-rw-r--r--common/stringhelp.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/common/stringhelp.h b/common/stringhelp.h
index adf2f2060..79d228415 100644
--- a/common/stringhelp.h
+++ b/common/stringhelp.h
@@ -33,6 +33,7 @@
#ifndef GNUPG_COMMON_STRINGHELP_H
#define GNUPG_COMMON_STRINGHELP_H
+#include <stdint.h>
#include "types.h"
/*-- stringhelp.c --*/
@@ -59,6 +60,7 @@ char *make_absfilename_try (const char *first_part,
...) GPGRT_ATTR_SENTINEL(0);
int compare_filenames( const char *a, const char *b );
+uint64_t string_to_u64 (const char *string);
int hextobyte (const char *s);
size_t utf8_charcount (const char *s, int len);