If the defendant in a real or mixed action dies before final judgment, his heir or devisee of the land demanded may, within such time as the court allows, appear and defend the action, which shall be conducted as if commenced against him. If the heir or devisee does not voluntarily appear, the court before whom the action is pending shall, upon the application of the plaintiff, summon such heir or devisee to appear and defend the action. If any of several defendants in such action dies before final judgment, the action may be prosecuted against the surviving defendants for so much of the land as they hold or claim.
Mass. Gen. Laws ch. 228, § 11