diskcache.c: Fix memory leak on error.

 * Reassign oldbuf to buff to free it on error.
diskcache.c: Fix a memory leak on failure.