thermal/core: Remove duplicate information when an error occurs