In the event the court does not hold the state liable for the costs in any cases when finally disposed of, it is the duty of the clerk to include all of the costs previously paid by the state on this account in the clerk's executions and the clerk's bill of costs, and to collect and refund the same to the state, in the same manner as the clerk is required by law to pay over state revenue.
T.C.A. § 40-25-121