Fixed handling of ending dtrace sessions.