Section 32. The pound keeper shall not deliver the beasts to the owner until his fees, the amount so demanded by the distrainor for the damages and charges aforesaid, the expense, if any, of advertising, and all other legal costs and expenses have been paid to him.