Add missing include, minor cleanup in diag output