Add a stat(memory)
Fixed null issue