replace m_new with m_new0, wherever reasonable, and remove dangling memory fragments created by m_new0