[ekiga] Fixed potential problem with emitted/received calls.
- From: Damien Sandras <dsandras src gnome org>
- To: svn-commits-list gnome org
- Subject: [ekiga] Fixed potential problem with emitted/received calls.
- Date: Wed, 22 Jul 2009 15:51:03 +0000 (UTC)
commit 9d3b7c444e4f4e1e81e8dcfde2bafc3e678ef814
Author: Damien Sandras <dsandras seconix com>
Date: Wed Jul 22 17:47:45 2009 +0200
Fixed potential problem with emitted/received calls.
Only rely on IsNetworkOriginated when the call has been setup.
lib/engine/components/opal/opal-call.cpp | 5 +++--
lib/engine/components/opal/opal-call.h | 2 ++
2 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/lib/engine/components/opal/opal-call.cpp b/lib/engine/components/opal/opal-call.cpp
index ca87a54..58a93d3 100644
--- a/lib/engine/components/opal/opal-call.cpp
+++ b/lib/engine/components/opal/opal-call.cpp
@@ -93,7 +93,7 @@ private:
Opal::Call::Call (OpalManager& _manager, const Ekiga::ServiceCore& _core, const std::string& uri)
: OpalCall (_manager), Ekiga::Call (), core (_core), remote_uri (uri),
- call_setup(false), jitter(0)
+ call_setup(false), outgoing(false), jitter(0)
{
re_a_bytes = tr_a_bytes = re_v_bytes = tr_v_bytes = 0.0;
last_v_tick = last_a_tick = PTime ();
@@ -279,7 +279,7 @@ Opal::Call::get_start_time () const
bool
Opal::Call::is_outgoing () const
{
- return !IsNetworkOriginated ();
+ return outgoing;
}
@@ -494,6 +494,7 @@ Opal::Call::OnAnswerCall (OpalConnection & connection,
PBoolean
Opal::Call::OnSetUp (OpalConnection & connection)
{
+ outgoing = !IsNetworkOriginated ();
parse_info (connection);
Ekiga::Runtime::emit_signal_in_main (setup);
diff --git a/lib/engine/components/opal/opal-call.h b/lib/engine/components/opal/opal-call.h
index 15298f2..96266e9 100644
--- a/lib/engine/components/opal/opal-call.h
+++ b/lib/engine/components/opal/opal-call.h
@@ -251,6 +251,8 @@ private:
unsigned out_of_order_v;
unsigned total_v;
+ bool outgoing;
+
private:
void on_cleared_call (std::string);
void on_missed_call ();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]