ยง 8015. County clerk where sheriff is a party or otherwise disqualified. A county clerk is entitled for the services specified to the following fees: 1. for performing any duty of a sheriff in an action in which the sheriff, for any cause, is disqualified, the same compensation to which a sheriff is entitled for the same services; and 2. for confining a sheriff in a house by virtue of a mandate, and maintaining him while there, two dollars for each day, to be paid by the sheriff, before he is entitled to be discharged.