Imporve handling of invalid packets

Improved handling of invalid packages as warnings,