The provisions of this chapter extend to the executor of a deceased surety and holder of the contract, but not to the official bonds of public officers, executors, or guardians.