summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--TAO/ChangeLog-98c32
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/24bit.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/2x2.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.cpp22
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h9
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2fast.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/gray.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybrid.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybriderr.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/jrevdct.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mb_ordered.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mono.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/motionvector.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered2.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util32.cpp1
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h3
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.cpp28
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h12
-rw-r--r--TAO/orbsvcs/tests/Sched_Conf/Sched_Conf.cpp25
24 files changed, 101 insertions, 47 deletions
diff --git a/TAO/ChangeLog-98c b/TAO/ChangeLog-98c
index d02e5cfde54..f4c4daa09d6 100644
--- a/TAO/ChangeLog-98c
+++ b/TAO/ChangeLog-98c
@@ -1,3 +1,35 @@
+Thu Aug 20 16:14:54 1998 Matthew J Braun <mjb2@cec.wustl.edu>
+
+ * orbsvcs/tests/Sched_Conf/Sched_Conf.cpp: Added Naming_Utils code
+ to simplify Naming Service operations
+
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util32.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered2.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/motionvector.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mono.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mb_ordered.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/jrevdct.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybriderr.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybrid.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/gray.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2fast.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/2x2.cpp
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/24bit.cpp
+ Added "ace/OS.h" to fix RCSID errors
+
+ * orbsvcs/tests/AVStreams/mpeg/source/server/server.{h,cpp}
+ * orbsvcs/tests/AVStreams/mpeg/source/server/augmented_server.{h,cpp}
+ * orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.{h,cpp}
+ Added Naming_Utils code to simplify Naming Service
+ operations. Also added "ace/OS.h" include to fix RCSID errors
+
+
Thu Aug 20 14:32:12 1998 Jeff Parsons <jp4@cs.wustl.edu>
* tao/Any.{h,i,cpp}:
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/24bit.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/24bit.cpp
index 140a242a9aa..6ec8d2bc06d 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/24bit.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/24bit.cpp
@@ -26,6 +26,7 @@
#include "video.h"
#include "dither.h"
#include "proto.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, 24bit, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/2x2.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/2x2.cpp
index 591dda96643..f12a0e070e5 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/2x2.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/2x2.cpp
@@ -26,6 +26,7 @@
#include "video.h"
#include "dither.h"
#include "proto.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, 2x2, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.cpp
index 361ed4e91b3..1b86a19c31d 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.cpp
@@ -82,6 +82,15 @@ Command_Handler::init (int argc,
TAO_TRY_ENV);
TAO_CHECK_ENV;
+ // Initialize the naming services
+ if (my_name_client_.init (orb_manager_.orb (),
+ argc,
+ argv) != 0)
+ ACE_ERROR_RETURN ((LM_ERROR,
+ " (%P|%t) Unable to initialize "
+ "the TAO_Naming_Client. \n"),
+ -1);
+
}
TAO_CATCHANY
{
@@ -216,23 +225,12 @@ Command_Handler::resolve_video_reference (void)
{
TAO_TRY
{
- CORBA::Object_var naming_obj =
- this->orb_manager_.orb ()->resolve_initial_references ("NameService");
- if (CORBA::is_nil (naming_obj.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to resolve the Name Service.\n"),
- -1);
- CosNaming::NamingContext_var naming_context =
- CosNaming::NamingContext::_narrow (naming_obj.in (),
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
CosNaming::Name video_server_mmdevice_name (1);
video_server_mmdevice_name.length (1);
video_server_mmdevice_name [0].id = CORBA::string_dup ("Video_Server_MMDevice");
CORBA::Object_var video_server_mmdevice_obj =
- naming_context->resolve (video_server_mmdevice_name,
+ my_name_client_->resolve (video_server_mmdevice_name,
TAO_TRY_ENV);
TAO_CHECK_ENV;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h
index d05d746d814..23e14ad95df 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h
@@ -24,7 +24,7 @@
* Department of Computer Science and Engineering
* email: scen@cse.ogi.edu
*/
-
+#include "ace/OS.h"
// ============================================================================
//
@@ -60,6 +60,7 @@
#include "orbsvcs/AV/AVStreams_i.h"
#include "ace/High_Res_Timer.h"
#include "ace/Acceptor.h"
+#include "orbsvcs/Naming/Naming_Utils.h"
@@ -286,7 +287,7 @@ public:
// Destructor
int init (int argc,char **argv);
- // initialize the ORB
+ // initialize the ORB and NamingService
int run (void);
// Run the ORB event loop
@@ -303,7 +304,6 @@ public:
const void *arg);
// handle the timeout
-
void stop_timer (void);
// stop the internal timer
@@ -420,6 +420,9 @@ private:
TAO_ORB_Manager orb_manager_;
// the ORB manager
+ TAO_Naming_Client my_name_client_;
+ // A Name_Client used to resolve the video_server_mmdevice
+
Video_Control_ptr video_control_;
// Video Control CORBA object
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h
index eaed06d00cb..37d2dfa93ce 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h
@@ -30,6 +30,7 @@
/* Include util.h for bit i/o parsing macros. */
#include "util.h"
+#include "ace/OS.h"
/* Code for unbound values in decoding tables */
#define ERROR -1
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h
index 3fa96c16e66..6cf228bf60b 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h
@@ -19,6 +19,7 @@
* ON AN "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO
* PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
*/
+#include "ace/OS.h"
typedef struct {
unsigned char value;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2fast.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2fast.cpp
index 8a80b67a1e5..616ffd7bcbe 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2fast.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2fast.cpp
@@ -26,6 +26,7 @@
#include "video.h"
#include "proto.h"
#include "dither.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, fs2fast, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h
index e63fcafa874..2109c6f6691 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h
@@ -19,6 +19,7 @@
* ON AN "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO
* PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
*/
+#include "ace/OS.h"
typedef struct {
unsigned char value;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/gray.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/gray.cpp
index b81dbaef06d..71aa8d295d5 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/gray.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/gray.cpp
@@ -26,6 +26,7 @@
#include "video.h"
#include "proto.h"
#include "dither.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, gray, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybrid.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybrid.cpp
index b26997ff946..b6e469d38e9 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybrid.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybrid.cpp
@@ -28,6 +28,7 @@
#include "video.h"
#include "proto.h"
#include "dither.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, hybrid, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybriderr.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybriderr.cpp
index 26021c15a60..274ef24cd2f 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybriderr.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/hybriderr.cpp
@@ -30,6 +30,7 @@
#include "video.h"
#include "proto.h"
#include "dither.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, hybriderr, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/jrevdct.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/jrevdct.cpp
index a35531a95ee..6114517c580 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/jrevdct.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/jrevdct.cpp
@@ -31,6 +31,7 @@
#include <string.h>
#include "video.h"
#include "proto.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, jrevdct, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mb_ordered.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mb_ordered.cpp
index b55ebb7a738..c1a69ad2041 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mb_ordered.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mb_ordered.cpp
@@ -27,6 +27,7 @@
#include "video.h"
#include "proto.h"
#include "dither.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, mb_ordered, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mono.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mono.cpp
index 53b815bf0f0..27e8c83a592 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mono.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mono.cpp
@@ -30,6 +30,7 @@
#include "video.h"
#include "proto.h"
#include "dither.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, mono, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/motionvector.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/motionvector.cpp
index 7581e4ecea7..e7a2407cd68 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/motionvector.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/motionvector.cpp
@@ -24,6 +24,7 @@
#include "video.h"
#include "proto.h"
#include "util.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, motionvector, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered.cpp
index 994ca29082a..5306f742242 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered.cpp
@@ -27,6 +27,7 @@
#include "video.h"
#include "proto.h"
#include "dither.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, ordered, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered2.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered2.cpp
index 587d5b831a3..5f8adb7da50 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered2.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ordered2.cpp
@@ -27,6 +27,7 @@
#include "video.h"
#include "proto.h"
#include "dither.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, ordered2, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.cpp
index f56861175ef..c266190b7fd 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.cpp
@@ -25,6 +25,7 @@
#include "video.h"
#include "proto.h"
#include "util.h"
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, util, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util32.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util32.cpp
index ef1e8fe0c4a..8ac1762823f 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util32.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util32.cpp
@@ -6,6 +6,7 @@
#include "video.h"
#include "proto.h"
#include "ui.h" /* include user interface */
+#include "ace/OS.h"
ACE_RCSID(mpeg_client, util32, "$Id$")
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h
index f6c011916ff..f7d2adae6e0 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h
@@ -29,4 +29,7 @@
len -- length of pattern and send pattern (number of frames);
f -- number of frames to send (represented by result send pattern);
*/
+#include "ace/OS.h"
+
void ComputeSendPattern(char * pat, char * buf, int len, int f);
+
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.cpp b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.cpp
index da0449ef1d0..2105d2b6fa7 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.cpp
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.cpp
@@ -175,7 +175,8 @@ AV_Server_Sig_Handler::remove_names (void)
{
TAO_TRY
{
- CORBA::Object_var naming_obj = TAO_ORB_Core_instance ()->orb ()->resolve_initial_references ("NameService");
+ CORBA::Object_var naming_obj =
+ TAO_ORB_Core_instance ()->orb ()->resolve_initial_references ("NameService");
if (CORBA::is_nil (naming_obj.in ()))
ACE_ERROR_RETURN ((LM_ERROR,
" (%P|%t) Unable to resolve the Name Service.\n"),
@@ -334,18 +335,15 @@ AV_Server::init (int argc,
ACE_ERROR_RETURN ((LM_ERROR,
"(%P|%t) Error parsing arguments"),
-1);
- // Resolve the Naming service reference.
- CORBA::Object_var naming_obj = orb->resolve_initial_references ("NameService");
- if (CORBA::is_nil (naming_obj.in ()))
+ // Initialize the naming services
+ if (my_name_client_.init (this->orb_manager_.orb (),
+ argc,
+ argv) != 0)
ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to resolve the Name Service.\n"),
- -1);
-
- this->naming_context_ =
- CosNaming::NamingContext::_narrow (naming_obj.in (),
- env);
- TAO_CHECK_ENV_RETURN (env,-1);
+ " (%P|%t) Unable to initialize "
+ "the TAO_Naming_Client. \n"),
+ -1);
// Register the video mmdevice object with the ORB
ACE_NEW_RETURN (this->video_mmdevice_,
@@ -364,14 +362,14 @@ AV_Server::init (int argc,
video_server_mmdevice_name [0].id = CORBA::string_dup ("Video_Server_MMDevice");
// Register the video control object with the naming server.
- this->naming_context_->bind (video_server_mmdevice_name,
+ this->my_name_client_->bind (video_server_mmdevice_name,
this->video_mmdevice_->_this (env),
env);
if (env.exception () != 0)
{
env.clear ();
- this->naming_context_->rebind (video_server_mmdevice_name,
+ this->my_name_client_->rebind (video_server_mmdevice_name,
this->video_mmdevice_->_this (env),
env);
TAO_CHECK_ENV_RETURN (env,-1);
@@ -396,14 +394,14 @@ AV_Server::init (int argc,
audio_server_mmdevice_name [0].id = CORBA::string_dup ("Audio_Server_MMDevice");
// Register the audio control object with the naming server.
- this->naming_context_->bind (audio_server_mmdevice_name,
+ this->my_name_client_->bind (audio_server_mmdevice_name,
this->audio_mmdevice_->_this (env),
env);
if (env.exception () != 0)
{
env.clear ();
- this->naming_context_->rebind (audio_server_mmdevice_name,
+ this->my_name_client_->rebind (audio_server_mmdevice_name,
this->audio_mmdevice_->_this (env),
env);
TAO_CHECK_ENV_RETURN (env,-1);
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h
index 8b061caf18e..4d34e1fdfda 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h
@@ -1,5 +1,5 @@
/* -*- c++ -*- */
-/* $Id$ */
+// $Id$
// ============================================================================
//
@@ -35,7 +35,7 @@
#include "mpeg_shared/routine.h"
#include "mpeg_shared/com.h"
#include "mpeg_server/Video_Control_i.h"
-#include "orbsvcs/orbsvcs/Naming/Naming_Utils.h"
+#include "orbsvcs/Naming/Naming_Utils.h"
#if defined (NATIVE_ATM)
#include "atmcom.h"
@@ -109,6 +109,10 @@ private:
ACE_HANDLE handle_;
// dummy handle for the sig handler.
ACE_Sig_Set sig_set;
+
+ TAO_Naming_Client my_name_client_;
+ // Name_Client used for unregistering the audio and video
+
};
class AV_Server
@@ -152,8 +156,8 @@ private:
TAO_ORB_Manager orb_manager_;
// the TAO ORB manager.
- CosNaming::NamingContext_var naming_context_;
- // The root naming context of the naming service
+ TAO_Naming_Client my_name_client_;
+ // Name_Server used to bind audio and video controls
AV_Server_Sig_Handler signal_handler_;
// Signal handler for SIGCHLD,SIGINT,SIGTERM,SIGBUS
diff --git a/TAO/orbsvcs/tests/Sched_Conf/Sched_Conf.cpp b/TAO/orbsvcs/tests/Sched_Conf/Sched_Conf.cpp
index 615918f41f1..6e77e941de8 100644
--- a/TAO/orbsvcs/tests/Sched_Conf/Sched_Conf.cpp
+++ b/TAO/orbsvcs/tests/Sched_Conf/Sched_Conf.cpp
@@ -9,6 +9,7 @@
#include "orbsvcs/CosNamingC.h"
#include "orbsvcs/Scheduler_Factory.h"
+#include "orbsvcs/Naming/Naming_Utils.h"
ACE_RCSID(Sched_Conf, Sched_Conf, "$Id$")
@@ -339,19 +340,17 @@ main (int argc, char *argv[])
PortableServer::POAManager_var poa_manager =
root_poa->the_POAManager (TAO_TRY_ENV);
TAO_CHECK_ENV;
-
- CORBA::Object_var naming_obj =
- orb->resolve_initial_references ("NameService");
- if (CORBA::is_nil(naming_obj.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to initialize the POA.\n"),
- 1);
-
- CosNaming::NamingContext_var naming_context =
- CosNaming::NamingContext::_narrow (naming_obj.in (), TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- if (ACE_Scheduler_Factory::use_config (naming_context.in (), service_name) < 0)
+
+ // Initialize the naming services
+ TAO_Naming_Client my_name_client;
+ if (my_name_client.init (orb.in (), argc, argv) != 0)
+ ACE_ERROR_RETURN ((LM_ERROR,
+ " (%P|%t) Unable to initialize "
+ "the TAO_Naming_Client. \n"),
+ -1);
+
+ if (ACE_Scheduler_Factory::use_config (my_name_client.get_context (),
+ service_name) < 0)
{
ACE_ERROR_RETURN ((LM_ERROR,
" (%P|%t) Unable to bind to the scheduling service.\n"),