libbb: change decode_base32/64 API to return the end of _dst_, not _src_.

function                                             old     new   delta
decode_base64                                        173     178      +5
read_base64                                          222     220      -2
decode_base32                                        186     182      -4
handle_incoming_and_exit                            2263    2239     -24
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/3 up/down: 5/-30)             Total: -25 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko
2020-11-28 13:26:44 +01:00
parent fc6faac84e
commit 885121e25d
3 changed files with 19 additions and 20 deletions

View File

@@ -1015,11 +1015,9 @@ static char *encodeString(const char *string)
* Parameter: a pointer to a base64 encoded string.
* Decoded data is stored in-place.
*/
static void decodeBase64(char *Data)
static void decodeBase64(char *data)
{
char *eptr = Data;
decode_base64(&eptr, Data);
*eptr = '\0';
decode_base64(data, NULL)[0] = '\0';
}
#endif