Changeset - deaa8e8dca9b
[Not reviewed]
0 1 0
HanzZ - 12 years ago 2013-02-24 10:50:24
hanzz.k@gmail.com
Load skype buddies from database if it's possible
1 file changed with 1 insertions and 0 deletions:
0 comments (0 inline, 0 general)
backends/skype/skype.cpp
Show inline comments
 
@@ -95,24 +95,25 @@ void Skype::login() {
 
		m_np->handleDisconnected(m_user, pbnetwork::CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE, "Invalid username");
 
		return;
 
	}
 

	
 
	m_db = createSkypeDirectory();
 

	
 
	bool spawned = spawnSkype(m_db);
 
	if (!spawned) {
 
		m_np->handleDisconnected(m_user, pbnetwork::CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE, "Error spawning the Skype instance.");
 
		return;
 
	}
 

	
 
	m_db += "/" + getUsername() + "/main.db";
 

	
 
	if (m_connection == NULL) {
 
		LOG4CXX_INFO(logger, "Creating DBUS connection.");
 
		GError *error = NULL;
 
		m_connection = dbus_g_bus_get(DBUS_BUS_SESSION, &error);
 
		if (m_connection == NULL && error != NULL)
 
		{
 
			LOG4CXX_INFO(logger,  m_username << ": Creating DBUS Connection error: " << error->message);
 
			g_error_free(error);
 
			return;
 
		}
 
	}
0 comments (0 inline, 0 general)