Dispatching events via |nsIThread| doesn't work with worker threads. This patch replaces all uses of |nsIThread| in the socket code by equivalent uses of |MessageLoop|.
Dispatching events via |nsIThread| doesn't work with worker threads. This patch replaces all uses of |nsIThread| in the socket code by equivalent uses of |MessageLoop|.