The plaintiff donated to the railroad company a right-of-way through an enclosed field belonging to him; the fence around this field came to the road-bed on each side of the same, and at each place where the road intersected the enclosure, stock-guards were placed by the company at both-the openings made in the enclosure by its road. The declaration alleged these facts; and further, that these guards were insufficient to keep the stock out of his field, on which was a growing crop of corn and other field . products; that, in consequence of the insufficiency of these stock-gaps or guards, hogs got into his field and .destroyed his growing crop ; that he was thus damaged by the negligent construction of these barriers to the ingress of stock, and by suffering-them to fall into decay and not keeping them in repair. No contract was set out, by which the company bound itself to protect the plaintiff’s field from the incursion and ravages of stock by undertaking to erect and maintain these gaps, and, at the hearing, the defendant demurred to the declaration, because it set forth no cause -of action. The demurrer was sustained, and the suit was dismissed. This judgment was assigned as error.
There is nothing in the assignment. The law does not impose upon the company the duty of making and keeping up these guards, and, in the absence of any agreement between the parties to that effect, we cannot infer that duty from the fact that the right-of way was the voluntary gift of the plaintiff. There was no such condition attached to the gift, and it is not to be presumed that it would have been accepted upon such terms. The company might not *356have been willing to accept it with the liability that.such an arrangement would have imposed. No right of the plaintiff has been violated by the defendant; it has been guilty of no breach, of duty, public or private, given by law, or flowing from relations created by contract, express or implied. Code, §§2951, 2953, 2954. The loss of the plaintiff is damnum absque injuria, and gives no right of action. To entitle a party to such.an action, there must be a violation of right, accompanied with damage. Id., ut sup.
Judgment affirmed.