Fix exceptions when the ignore file contains empty lines and when grep return error with code other than 1