Memory: fixes problems with anonymous memory