diff options
author | Werner Koch <wk@gnupg.org> | 2004-02-10 20:27:54 +0100 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2004-02-10 20:27:54 +0100 |
commit | f0d63ef75d2f03d41260e2c6a9f277cbcd71987a (patch) | |
tree | 3f18ce280ff38cf44e78741850cfec9848506bdf /common/util.h | |
parent | * minip12.c (parse_bag_encrypted_data): Finished implementation. (diff) | |
download | gnupg2-f0d63ef75d2f03d41260e2c6a9f277cbcd71987a.tar.xz gnupg2-f0d63ef75d2f03d41260e2c6a9f277cbcd71987a.zip |
New. Based on code from ../sm/base64.c.
Diffstat (limited to 'common/util.h')
-rw-r--r-- | common/util.h | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/common/util.h b/common/util.h index 7e134e846..ca7266627 100644 --- a/common/util.h +++ b/common/util.h @@ -1,5 +1,5 @@ -/* util.h - Utility functions for Gnupg - * Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. +/* util.h - Utility functions for GnuPG + * Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. * * This file is part of GnuPG. * @@ -98,6 +98,22 @@ int answer_is_yes_no_default (const char *s, int def_answer); int answer_is_yes_no_quit (const char *s); +/*-- b64enc.c --*/ +struct b64state +{ + unsigned int flags; + int idx; + int quad_count; + FILE *fp; + char *title; + unsigned char radbuf[4]; +}; +gpg_error_t b64enc_start (struct b64state *state, FILE *fp, const char *title); +gpg_error_t b64enc_write (struct b64state *state, + const void *buffer, size_t nbytes); +gpg_error_t b64enc_finish (struct b64state *state); + + /*-- miscellaneous.c --*/ /* Same as asprintf but return an allocated buffer suitable to be |