Added counter for panics.