ekiga r6472 - in trunk: . src/endpoints



Author: dsandras
Date: Thu Jul 17 21:06:38 2008
New Revision: 6472
URL: http://svn.gnome.org/viewvc/ekiga?rev=6472&view=rev

Log:
Fixed outgoing identity to ekiga.net account if we do not know what
identity to use.


Modified:
   trunk/ChangeLog
   trunk/src/endpoints/sip.cpp

Modified: trunk/src/endpoints/sip.cpp
==============================================================================
--- trunk/src/endpoints/sip.cpp	(original)
+++ trunk/src/endpoints/sip.cpp	Thu Jul 17 21:06:38 2008
@@ -886,9 +886,6 @@
 
 SIPURL CallProtocolManager::GetRegisteredPartyName (const SIPURL & host)
 {
-  //FIXME
-  //GmAccount *account = NULL;
-
   PString local_address;
   PIPSocket::Address address;
   WORD port;
@@ -911,18 +908,11 @@
      */
     if (host.GetHostAddress ().GetIpAndPort (address, port) && !manager.IsLocalAddress (address)) {
 
-      /*
-      account = gnomemeeting_get_default_account ("SIP");
-      if (account && account->enabled) {
-
-        if (PString(account->username).Find("@") == P_MAX_INDEX)
-          url = PString (account->username) + "@" + PString (account->host);
-        else
-          url = PString (account->username);
-
-        return SIPURL ("\"" + GetDefaultDisplayName () + "\" <" + url + ">");
-      }
-          */
+      Ekiga::AccountCore *account_core = dynamic_cast<Ekiga::AccountCore *> (core.get ("account-core"));
+      Ekiga::Account *account = account_core->find_account ("ekiga.net");
+
+      if (account)
+        return SIPURL ("\"" + GetDefaultDisplayName () + "\" <" + account->get_aor () + ">");
     }
   }
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]