Further cleanup, use LogDebug
Turn unique_ptr to regular pointer

Introduces a memory leak, but avoids a semi-random segfault.