In law, the rule is:
“Emergency” trumps everything.
The man is innocent. (well, he’s “not guilty”, I’ll need to check Black’s 6th...)
I believe it is called “competing harms.” As in you can’t be trespassing for jumping a fence to pull someone from a burning building.