summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormcorino <mcorino@users.noreply.github.com>2009-12-10 13:44:38 +0000
committermcorino <mcorino@users.noreply.github.com>2009-12-10 13:44:38 +0000
commit94eb88f90d48ad9e02173dfeac194c65fd8fcc77 (patch)
treee9370501c3e238bf5f52fe8192243a4e491b138c
parent31ebb931d537f88b8c8a62b15d5e9c431d49967c (diff)
downloadATCD-94eb88f90d48ad9e02173dfeac194c65fd8fcc77.tar.gz
Thu Dec 10 13:45:00 UTC 2009 Martin Corino <mcorino@remedy.nl>
* tests/Oneways_Invoking_Twoways/Client_Task.cpp: * tests/Oneways_Invoking_Twoways/Receiver_i.cpp: * tests/Oneways_Invoking_Twoways/client.cpp: * tests/Oneways_Invoking_Twoways/Sender_i.cpp: * tests/Oneways_Invoking_Twoways/run_test.pl: Changed to fix problems with incorrect shutdown sequence (see Bugzilla 2068).
-rw-r--r--TAO/ChangeLog10
-rw-r--r--TAO/tests/Oneways_Invoking_Twoways/Client_Task.cpp6
-rw-r--r--TAO/tests/Oneways_Invoking_Twoways/Receiver_i.cpp2
-rw-r--r--TAO/tests/Oneways_Invoking_Twoways/Sender_i.cpp2
-rw-r--r--TAO/tests/Oneways_Invoking_Twoways/client.cpp14
-rwxr-xr-xTAO/tests/Oneways_Invoking_Twoways/run_test.pl2
6 files changed, 25 insertions, 11 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index b79660b2c50..f12034367d8 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,13 @@
+Thu Dec 10 13:45:00 UTC 2009 Martin Corino <mcorino@remedy.nl>
+
+ * tests/Oneways_Invoking_Twoways/Client_Task.cpp:
+ * tests/Oneways_Invoking_Twoways/Receiver_i.cpp:
+ * tests/Oneways_Invoking_Twoways/client.cpp:
+ * tests/Oneways_Invoking_Twoways/Sender_i.cpp:
+ * tests/Oneways_Invoking_Twoways/run_test.pl:
+ Changed to fix problems with incorrect shutdown sequence
+ (see Bugzilla 2068).
+
Thu Dec 10 13:03:58 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl>
Reverted change below, causes correct code to break
diff --git a/TAO/tests/Oneways_Invoking_Twoways/Client_Task.cpp b/TAO/tests/Oneways_Invoking_Twoways/Client_Task.cpp
index 23c42f4ba1a..738d0e312ed 100644
--- a/TAO/tests/Oneways_Invoking_Twoways/Client_Task.cpp
+++ b/TAO/tests/Oneways_Invoking_Twoways/Client_Task.cpp
@@ -38,12 +38,6 @@ Client_Task::svc (void)
// this poorly implemented test used to take
while (this->receiver_impl_->no_calls_ < 10)
ACE_OS::sleep (1);
-
- this->us_->shutdown ();
- // give the processes an additional second to finish up any
- // lagging invocations, cleanups etc.
- ACE_OS::sleep (1);
- this->sender_->shutdown ();
}
catch (const CORBA::Exception& ex)
{
diff --git a/TAO/tests/Oneways_Invoking_Twoways/Receiver_i.cpp b/TAO/tests/Oneways_Invoking_Twoways/Receiver_i.cpp
index 6646e95283c..570a06fe83b 100644
--- a/TAO/tests/Oneways_Invoking_Twoways/Receiver_i.cpp
+++ b/TAO/tests/Oneways_Invoking_Twoways/Receiver_i.cpp
@@ -39,6 +39,6 @@ void
Receiver_i::shutdown (void)
{
ACE_DEBUG ((LM_DEBUG,
- "(%P|%t) About to invoke shudown...\n"));
+ "(%P|%t) About to invoke shutdown...\n"));
this->orb_->shutdown (0);
}
diff --git a/TAO/tests/Oneways_Invoking_Twoways/Sender_i.cpp b/TAO/tests/Oneways_Invoking_Twoways/Sender_i.cpp
index d7920f91791..5e408c90e49 100644
--- a/TAO/tests/Oneways_Invoking_Twoways/Sender_i.cpp
+++ b/TAO/tests/Oneways_Invoking_Twoways/Sender_i.cpp
@@ -50,6 +50,6 @@ void
Sender_i::shutdown (void)
{
ACE_DEBUG ((LM_DEBUG,
- "(%P|%t) About to invoke shudown...\n"));
+ "(%P|%t) About to invoke shutdown...\n"));
this->orb_->shutdown (0);
}
diff --git a/TAO/tests/Oneways_Invoking_Twoways/client.cpp b/TAO/tests/Oneways_Invoking_Twoways/client.cpp
index 7adc60840d8..50932a36842 100644
--- a/TAO/tests/Oneways_Invoking_Twoways/client.cpp
+++ b/TAO/tests/Oneways_Invoking_Twoways/client.cpp
@@ -116,8 +116,18 @@ ACE_TMAIN(int argc, ACE_TCHAR *argv[])
ACE_ERROR ((LM_ERROR, "Error activating client task\n"));
}
- ACE_Thread_Manager::instance ()->wait ();
-
+ // wait for oneway sends and twoway replies to be processed
+ client_task.wait ();
+
+ // shutdown server
+ sender->shutdown ();
+
+ // shutdown ourself
+ receiver->shutdown ();
+
+ // wait for event loop to finish
+ server_task.wait ();
+
ACE_DEBUG ((LM_DEBUG,
"Event Loop finished\n"));
diff --git a/TAO/tests/Oneways_Invoking_Twoways/run_test.pl b/TAO/tests/Oneways_Invoking_Twoways/run_test.pl
index ade82b1de73..7f1046368ff 100755
--- a/TAO/tests/Oneways_Invoking_Twoways/run_test.pl
+++ b/TAO/tests/Oneways_Invoking_Twoways/run_test.pl
@@ -41,7 +41,7 @@ if ($client_status != 0) {
$status = 1;
}
-$server_status = $SV->TerminateWaitKill ($server->ProcessStopWaitInterval());
+$server_status = $SV->WaitKill ($server->ProcessStopWaitInterval());
if ($server_status != 0) {
print STDERR "ERROR: server returned $server_status\n";