fix regression (mem leak during normal operations) from commit b7a34ab022b4f427d0a73fc6ac37230e1ca29a84