Revert "Use a variable on the stack to not have a temporary in the call"
[ACE_TAO.git] / TAO / tests / NestedUpcall / Triangle_Test / Object_B_i.cpp
blob99b748b2862d421b09ba7d16ca4b90911c29b0c5
2 //=============================================================================
3 /**
4 * @file Object_B_i.cpp
6 * This class implements the Object B of the
7 * Nested Upcalls - Triangle test.
9 * @author Michael Kircher
11 //=============================================================================
14 #include "tao/Exception.h"
15 #include "Object_B_i.h"
16 #include "ace/OS_NS_unistd.h"
18 // CTOR
19 Object_B_i::Object_B_i ()
23 // DTOR
24 Object_B_i::~Object_B_i ()
29 void
30 Object_B_i::foo (Object_A_ptr theObject_A_ptr)
32 try
34 ACE_DEBUG ((LM_DEBUG,
35 "(%P|%t) BEGIN Object_B_i::foo: Trying to call Object A\n"));
37 theObject_A_ptr->finish ();
39 // Start to wait on this variable, it is set to true
40 // by the method finish ()
41 long int usecs = 500000;
42 ACE_Time_Value pause(0, usecs);
44 ACE_OS::sleep(pause);
46 catch (const CORBA::Exception& ex)
48 ex._tao_print_exception ("calling the initiator");
53 void
54 Object_B_i::shutdown ()
56 int argc = 0;
57 ACE_TCHAR **argv = 0;
58 CORBA::ORB_var orb = CORBA::ORB_init (argc, argv);
60 orb->shutdown ();