PMC: Fix buffer overflow in logging