failure case memory leak in base32_decode
It's trivial, but base32_decode mallocates a "tmp" variable which is not freed in the "illegal character in base32 encoded string" case.
... /* Convert base32 encoded chars to the 5-bit values that they represent. */ tmp = tor_malloc_zero(srclen); for (j = 0; j < srclen; ++j) { if (src[j] > 0x60 && src[j] < 0x7B) tmp[j] = src[j] - 0x61; else if (src[j] > 0x31 && src[j] < 0x38) tmp[j] = src[j] - 0x18; else { log_warn(LD_BUG, "illegal character in base32 encoded string"); return -1; } } ...
[Automatically added by flyspray2trac: Operating System: All]
Trac:
Username: ghazel