[omniORB] Compiler warnings in 4.1

Tamas Kerecsen kerecsen at gmail.com
Sun Sep 10 23:57:58 BST 2006


Duncan,

While cleaning up some makefiles and setting warning-levels to more paranoid
heights, I noticed that the omniORB headers have a few minor issues when the
warnings are set up just right in gcc 3.4.5.

All the warnings I saw complained about one class or the other not calling
its parent class' copy constructor from its own copy constructor (I always
wondered if it would have been better to design the C++ language so copy
constructors call their parent copy constructors instead of the default
constructors). It seems like it's not a real issue, because all the parent
copy constructors are empty. But just to appease the compiler (and to
prevent a big old gotcha' moment in the future if something gets added to
the parent copy constructors), could you put in those calls to the parent
copy constructor?

Thanks,
  Tamas

Here are the warnings gcc gave me:

../../../../../1kx1k/Linux/ThirdParty/omniORB/include/omniORB4/poa.h: In
copy constructor `PortableServer::ServantBase::ServantBase(const
PortableServer::ServantBase&)':

../../../../../1kx1k/Linux/ThirdParty/omniORB/include/omniORB4/poa.h:667:
warning: base class `class omniServant' should be explicitly initialized in
the copy constructor

../../../../../1kx1k/Linux/ThirdParty/omniORB/include/omniORB4/CORBA_ValueBase.h:
In copy constructor
`CORBA::DefaultValueRefCountBase::DefaultValueRefCountBase(const
CORBA::DefaultValueRefCountBase&)':

../../../../../1kx1k/Linux/ThirdParty/omniORB/include/omniORB4/CORBA_ValueBase.h:177:
warning: base class `class CORBA::ValueBase' should be explicitly
initialized in the copy constructor

../../../../../1kx1k/Linux/ThirdParty/omniORB/include/omniORB4/boxes_defs.hh:
In copy constructor `CORBA::StringValue::StringValue(const
CORBA::StringValue&)':

../../../../../1kx1k/Linux/ThirdParty/omniORB/include/omniORB4/boxes_defs.hh:33:
warning: base class `class CORBA::ValueBase' should be explicitly
initialized in the copy constructor

../../../../../1kx1k/Linux/ThirdParty/omniORB/include/omniORB4/boxes_defs.hh:
In copy constructor `CORBA::WStringValue::WStringValue(const
CORBA::WStringValue&)':
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20060910/83027c53/attachment.htm


More information about the omniORB-list mailing list