libbb: split decode_base64 off read_base64

function                                             old     new   delta
decode_base64                                          -     182    +182
read_base64                                          378     255    -123
------------------------------------------------------------------------------
(add/remove: 1/0 grow/shrink: 0/1 up/down: 182/-123)           Total: 59 bytes

Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Leonid Lisovskiy
2011-10-28 13:59:04 +02:00
committed by Denys Vlasenko
parent ec447c7f01
commit 328f27fe44
3 changed files with 200 additions and 29 deletions

View File

@ -1591,7 +1591,8 @@ enum {
/* Sign-extends to a value which never matches fgetc result: */
BASE64_FLAG_NO_STOP_CHAR = 0x80,
};
void FAST_FUNC read_base64(FILE *src_stream, FILE *dst_stream, int flags);
const char *decode_base64(char **pp_dst, const char *src) FAST_FUNC;
void read_base64(FILE *src_stream, FILE *dst_stream, int flags) FAST_FUNC;
typedef struct md5_ctx_t {
uint8_t wbuffer[64]; /* always correctly aligned for uint64_t */