logging: Cleaned up cmd_log