Bug 1016265 - Ensure the Session object is destroyed on main thread and add assertion and warning if dispatch runnable failed. r=roc