necessity

The invasion of the private rights of others may possibly be justified and defended on the grounds of necessity. Thus to destroy property in the path of a conflagration to halt it, or to enter on property and damage it in time of war may be justified as for the commonweal. Similarly, acts injurious to others may be done in the defence of a mans own property which is in imminent danger. Thus a farmer may shoot a savage dog which is attacking his sheep. The test is whether there was reasonable necessity for doing the act done in the circumstances existing at the time. Necessity may be an excuse for committing what would otherwise be a criminal offence if the act or omission which is in question was necessary to prevent the execution of an illegal purpose. But mere personal necessity is no justification for a crime, e.g. hunger.