partial fix on memory