Updated memorymb to avoid NPE