Sherwin, J.—
*6151. Animals: running at iarge: injury recovery of damages. *614The evidence tends to show that the plaintiff’s horse was at large on the public highway near the defendant’s residence, and that, while it was -quietly walking along the road, it was attacked by the defendant’s dogs, was chased by them some distance and badly frightened; *615that after the dogs had abandoned the chase, the horse continued to run rapidly towards the plaintiff’s house, which was over two miles from the defendant’s and that when nearly home it ran int0 a wire fence and received injuries which resulted in its death. The court submitted to the jury the question whether the horse was running at large when it was attacked, and told the jury that if it was there could be no recovery, because the herd law was then in force in the county. It was error to so instruct. Section 2340 of the Code imposes liability for damages caused by dogs, except when the-party injured “is doing an unlawful act.” The unlawful act that will defeat liability must be one that directly contributes to the injury sustained; otherwise, it is no defense. Schmid v. Humphrey, 48 Iowa, 652; Gross v. Miller, 93 Iowa, 72; Matthes v. Acc. Ass’n, 110 Iowa, 222; Shultz v. Griffith, 103 Iowa, 150. The defendant did not plead that the plaintiff was doing an unlawful act that contributed to his injury, but the court admitted evidence tending to so show and instructed on the subject. This the appellant assigns as error. It is the rule that an affirmative defense must be pleaded, and, unless there are some'reasons why a different rule should obtain in this case, there was error in admitting the evidence and in instructing as the court did.
The appellee contends that, under the rule in Gregory v. Woodworth, 93 Iowa, 246, followed in Stuber v. Gannon, 98 Iowa, 228, the plaintiff was bound to plead and prove his freedom from contributory negligence, and that being true, that it was competent for the defendant to prove an unlawful act on the part of the plaintiff without pleading the same. It will be observed that the statute makes the owner of the dog absolutely liable for an injury inflicted by him, “ except when the party is doing an unlawful act.” While we have held in these cases that the unlawful act that will relieve the owner of the dog from liability must be an act *616amounting to negligence, we have also held that mere negligence, not amounting to an unlawful act, is no defense. Shultz v. Griffith, supra; Van Bergen v. Eulberg, 111 Iowa, 139. Moreover, to exempt from liability, the party must be doing an unlawful act at the time of the attack. Van Bergen v. Eulberg, supra. It is clear, therefore, that the defendant must plead and prove the unlawful act on which he relies to defeat his liability; and it is equally as clear that permitting an animal to run at large in the public highway is not such an unlawful act as is contemplated by the statute. So far, then, as the cases of Gregory v. Woodworth and Stuber v. Gannon, supra, conflict with this view they must be and they, are overruled.
2. Same: proxintervening structlon. The court further instructed as follows: “ Damages to be recoverable must be the proximate consequence of the act complained of; that it must be the consequence that follows the act, and not the secondary result df the first consequence, either alone or in combination with other circumstances. And in order to find that the injury and death of said mare was the proximate result of the acts of said dogs you must find that there was no subsequent intervening cause. It' is claimed that another cause, viz., the striking of the tug, contributed to the running away of the mare. You are instructed that where two or more causes concur to produce an effect, and it cannot be determined whether without the concurrence of both it would not have occurred, and a particular party is responsible for only one of the causes, recovery cannot be had against said party.” The instruction is assailed because it relieved the defendant from liability, although the contributory cause therein referred to may have been the result of his original wrong. As applied to the facts in this case, we think the instruction misleading and erroneous. If the horse was'in fact so frightened by the defendant’s dogs that it ran violently, and if such running put in motion the tug that it 'is claimed kept whipping it and thus kept it *617going, the action of the tug was an incident to the original cause which might reasonably have been foreseen. For illustration, if the defendant himself saw the horse traveling quietly along the highway, with a tug of its harness dragging on the ground and started it to running, he 'might reasonably expect that the tug would strike the horse, for that is a matter of common observation. And, if the action of the dogs was the active, efficient cause that set in motion the tug, although it may later have contributed to the fright of the horse, such action was the direct proximate cause of the injury within the law. In such ease the intervening cause was not an independent cause sufficient of itself to produce the results. 1 Thompson on Negligence, sections 49, 51, 52, 54. Pratt v. Chicago, R. I. & P. Ry. Co., 107 Iowa, 287; Gould v. Schermer, 101 Iowa, 582.
The judgment is reversed.