There is a newer version of the Maryland Code
Maryland Family Law Section 11-108
Unless the parties agree otherwise, alimony terminates:
(1)   on the death of either party;
(2)   on the marriage of the recipient; or
(3)   if the court finds that termination is necessary to avoid a harsh and inequitable result.