﻿id,summary,reporter,owner,description,type,status,priority,milestone,component,version,resolution,keywords,cc
175,libpurple API called from different threads,cavedon,vadim,"libpurple is not thread safe add all API must be called from the *same* thread:
http://developer.pidgin.im/wiki/WhatIsLibpurple#Isitthreaded

In the current implementation, libpurple is initialized in 
PurpleIMFactory::PurpleIMInit(), but all other operations are handled by a glib event loop PurpleMainEventLoop() running in a seperate thread created by PurpleIMFactory::PurpleIMFactory

For this reason, libpurple might crash in very weird ways (as I actually found trying to use an external libpurple compiled against nss).

I think the easiest way should be handling initialization and every call to libpurple de-initialization of liburple inside that glib loop (which is created before initializing libpurple).

The alternative, more efficient, would be to get rid of the glib event loop and sue WengoPhone::runEvents() even loop also for libpurple. I do not know how hard it is tough, as it should also handle event on sockets.",defect,reopened,critical,QuteCom 3.0,misc,2.2,,,
