Fix for linux; added error output cor CP