When a tenant for life shall demise any lands and shall die on or after the day when any rent becomes due and payable, his executors or administrators may recover from the under-tenant the whole rent due, but if any such tenant for life shall die before the day when any rent is to become due, his executors or administrators may recover the proportion of rent which accrued before his death, and the remainderman shall recover for the residue.