[omniORB] Troubles with wstring

Giuseppe Naccarato giuseppe.naccarato@picsel.com
Mon Nov 25 13:36:01 2002


Duncan Grisby wrote:

>
> I can't see anything wrong with your usage of wstring. I suspect that
> it's an issue with mixing debug settings in VC++. Make sure you are
> using the debug or non debug versions of the omniORB libraries to
> match the setting of your program.
>
> Just to be certain, you might try to see if your server works with an
> omniORB client. If it does, omniORB must be getting upset with
> something the Java ORB is doing. In that case, please post a trace
> from omniORB with -ORBtraceLevel 40.
>

I'm compiling in debug mode and using these libs:

omniDynamic400_rtd.lib
ominiORB400_rtd.lib
omnithread30_rtd.lib

This is the complete trace:

C:\giuseppe\trunk\messenger-server\epagetest\corba-OmniOrb4.0\cpp>debug\fooserve

r.exe -ORBInitRef NameService=corbaname::localhost:2809 -ORBtraceLevel 40
omniORB: Configuration file "./omniORB.cfg" either does not exist or is
not a fi
le. No settings read.
omniORB: Distribution date: Sun Sep 22 22:06:56 BST 2002 dgrisby
omniORB: My addresses are:
omniORB: 195.171.216.129
omniORB: 127.0.0.1
omniORB: Maximum supported GIOP version is 1.2
omniORB: Native char code sets: UTF-8 ISO-8859-1.
omniORB: Transmission char code sets: UTF-8(1.2) ISO-8859-1(1.2)
ISO-8859-1(1.1)
 ISO-8859-1(1.0).
omniORB: Native wide char code sets: UTF-16.
omniORB: Transmission wide char code sets: UTF-16(1.2).
omniORB: Initialising omniDynamic library.
omniORB: Current configuration is as follows:
omniORB:   DefaultInitRef =
omniORB:   InitRef = NameService=corbaname::localhost:2809
omniORB:   abortOnInternalError = 0
omniORB:   acceptBiDirectionalGIOP = 0
omniORB:   acceptMisalignedTcIndirections = 0
omniORB:   bootstrapAgentHostname =
omniORB:   bootstrapAgentPort = 900
omniORB:   clientCallTimeOutPeriod = 0
omniORB:   clientTransportRule = * unix,ssl,tcp
omniORB:   diiThrowsSysExceptions = 0
omniORB:   dumpConfiguration = 0
omniORB:   endPoint = giop:tcp::
omniORB:   endPointPublishAllIFs = 0
omniORB:   giopMaxMsgSize = 2097152
omniORB:   giopTargetAddressMode = KeyAddr
omniORB:   id = omniORB4
omniORB:   inConScanPeriod = 180
omniORB:   lcdMode = 0
omniORB:   maxGIOPConnectionPerServer = 5
omniORB:   maxGIOPVersion = 1.2
omniORB:   maxInterleavedCallsPerConnection = 5
omniORB:   maxServerThreadPerConnection = 100
omniORB:   maxServerThreadPoolSize = 100
omniORB:   nativeCharCodeSet = ISO-8859-1
omniORB:   nativeWCharCodeSet = UTF-16
omniORB:   objectTableSize = 0
omniORB:   offerBiDirectionalGIOP = 0
omniORB:   omniORB_27_CompatibleAnyExtraction = 0
omniORB:   oneCallPerConnection = 1
omniORB:   outConScanPeriod = 120
omniORB:   poaHoldRequestTimeout = 0
omniORB:   principal = [Null]
omniORB:   scanGranularity = 5
omniORB:   serverCallTimeOutPeriod = 0
omniORB:   serverTransportRule = * unix,ssl,tcp
omniORB:   strictIIOP = 1
omniORB:   supportBootstrapAgent = 0
omniORB:   supportCurrent = 1
omniORB:   tcAliasExpand = 0
omniORB:   threadPerConnectionLowerLimit = 9000
omniORB:   threadPerConnectionPolicy = 1
omniORB:   threadPerConnectionUpperLimit = 10000
omniORB:   threadPoolWatchConnection = 1
omniORB:   traceInvocations = 0
omniORB:   traceLevel = 40
omniORB:   traceThreadId = 0
omniORB:   unixTransportDirectory = /tmp/omni-%u
omniORB:   unixTransportPermission =  777
omniORB:   useTypeCodeIndirections = 1
omniORB:   verifyObjectExistsAndType = 1
omniORB: Initialising incoming endpoints.
omniORB: Starting serving incoming endpoints.
omniORB: Adding root<0> (activating) to object table.
omniORB: State root<0> (activating) -> active
omniORB: Creating ref to local: root<0>
 target id      : IDL:Foo:1.0
 most derived id: IDL:Foo:1.0
omniORB: Creating ref to remote: key<0x4e616d6553657276696365>
 target id      : IDL:omg.org/CORBA/Object:1.0
 most derived id:
omniORB: Initial reference `NameService' resolved from -ORBInitRef
argument / OR
B registration.
omniORB: AsyncInvoker: thread id = 1 has started. Total threads = 2
omniORB: giopRendezvouser task execute for giop:tcp:195.171.216.129:1402
omniORB: AsyncInvoker: thread id = 2 has started. Total threads = 2
omniORB: Scavenger task execute.
omniORB: Client opened connection to giop:tcp:127.0.0.1:2809
omniORB: sendChunk: to giop:tcp:127.0.0.1:2809 100 bytes
4749 4f50 0100 0100 5800 0000 0000 0000 GIOP....X.......
0200 0000 01cd cdcd 0b00 0000 4e61 6d65 ............Name
5365 7276 6963 65cd 0600 0000 5f69 735f Service....._is_
6100 cdcd 0000 0000 2800 0000 4944 4c3a a.......(...IDL:
6f6d 672e 6f72 672f 436f 734e 616d 696e omg.org/CosNamin
672f 4e61 6d69 6e67 436f 6e74 6578 743a g/NamingContext:
312e 3000                               1.0.
omniORB: inputMessage: from giop:tcp:127.0.0.1:2809 400 bytes
4749 4f50 0100 0001 0000 0184 0000 0002 GIOP............
0000 0006 0000 00a4 0000 0000 0000 0028 ...............(
4944 4c3a 6f6d 672e 6f72 672f 5365 6e64 IDL:omg.org/Send
696e 6743 6f6e 7465 7874 2f43 6f64 6542 ingContext/CodeB
6173 653a 312e 3000 0000 0001 0000 0000 ase:1.0.........
0000 0068 0001 0200 0000 0010 3139 352e ...h........195.
3137 312e 3231 362e 3132 3900 0af9 0000 171.216.129.....
0000 0019 afab cb00 0000 0002 bb5e e894 .............^..
0000 0008 0000 0001 0000 0000 0a00 0000 ................
0000 0001 0000 0001 0000 0020 0000 0000 ........... ....
0001 0001 0000 0002 0501 0001 0001 0020 ...............
0001 0109 0000 0001 0001 0100 4e45 4f00 ............NEO.
0000 0002 000a 0000 0000 0002 0000 0003 ................
0000 002b 4944 4c3a 6f6d 672e 6f72 672f ...+IDL:omg.org/
436f 734e 616d 696e 672f 4e61 6d69 6e67 CosNaming/Naming
436f 6e74 6578 7445 7874 3a31 2e30 0000 ContextExt:1.0..
0000 0001 0000 0000 0000 0084 0001 0200 ................
0000 0010 3139 352e 3137 312e 3231 362e ....195.171.216.
3132 3900 0af9 0000 0000 0035 afab cb00 129........5....
0000 0020 bb5e e894 0000 0001 0000 0000 ... .^..........
0000 0001 0000 000d 544e 616d 6553 6572 ........TNameSer
7669 6365 0000 0000 0000 0004 0000 0000 vice............
0a00 0000 0000 0001 0000 0001 0000 0020 ...............
0000 0000 0001 0001 0000 0002 0501 0001 ................
0001 0020 0001 0109 0000 0001 0001 0100 ... ............
omniORB: Creating ref to remote:
key<0xafabcb0000000020bb5ee89400000001000000000
00000010000000d544e616d65536572766963650000000000000004000000000a>
 target id      : IDL:omg.org/CORBA/Object:1.0
 most derived id: IDL:omg.org/CosNaming/NamingContextExt:1.0
omniORB: GIOP::LOCATION_FORWARD -- retry request.
omniORB: omniRemoteIdentity deleted.
omniORB: ObjRef(IDL:omg.org/CosNaming/NamingContextExt:1.0) -- deleted.
omniORB:  send codeset service context: (ISO-8859-1,UTF-16)
omniORB: Client opened connection to giop:tcp:195.171.216.129:2809
omniORB: sendChunk: to giop:tcp:195.171.216.129:2809 164 bytes
4749 4f50 0102 0100 9800 0000 0200 0000 GIOP............
0300 0000 0000 cdcd 3500 0000 afab cb00 ........5.......
0000 0020 bb5e e894 0000 0001 0000 0000 ... .^..........
0000 0001 0000 000d 544e 616d 6553 6572 ........TNameSer
7669 6365 0000 0000 0000 0004 0000 0000 vice............
0acd cdcd 0600 0000 5f69 735f 6100 cdcd ........_is_a...
0100 0000 0100 0000 0c00 0000 0100 0000 ................
0100 0100 0901 0100 2800 0000 4944 4c3a ........(...IDL:
6f6d 672e 6f72 672f 436f 734e 616d 696e omg.org/CosNamin
672f 4e61 6d69 6e67 436f 6e74 6578 743a g/NamingContext:
312e 3000                               1.0.
omniORB: inputMessage: from giop:tcp:195.171.216.129:2809 209 bytes
4749 4f50 0102 0001 0000 00c5 0000 0002 GIOP............
0000 0000 0000 0002 0000 0006 0000 00a4 ................
0000 0000 0000 0028 4944 4c3a 6f6d 672e .......(IDL:omg.
6f72 672f 5365 6e64 696e 6743 6f6e 7465 org/SendingConte
7874 2f43 6f64 6542 6173 653a 312e 3000 xt/CodeBase:1.0.
0000 0001 0000 0000 0000 0068 0001 0200 ...........h....
0000 0010 3139 352e 3137 312e 3231 362e ....195.171.216.
3132 3900 0af9 0000 0000 0019 afab cb00 129.............
0000 0002 bb5e e894 0000 0008 0000 0001 .....^..........
0000 0000 0a00 0000 0000 0001 0000 0001 ................
0000 0020 0000 0000 0001 0001 0000 0002 ... ............
0501 0001 0001 0020 0001 0109 0000 0001 ....... ........
0001 0100 4e45 4f00 0000 0002 000a 0000 ....NEO.........
01                                      .
omniORB: Creating ref to remote:
key<0xafabcb0000000020bb5ee89400000001000000000
00000010000000d544e616d65536572766963650000000000000004000000000a>
 target id      : IDL:omg.org/CosNaming/NamingContext:1.0
 most derived id:
omniORB: sendChunk: to giop:tcp:195.171.216.129:2809 264 bytes
4749 4f50 0102 0100 fc00 0000 0400 0000 GIOP............
0300 0000 0000 cdcd 3500 0000 afab cb00 ........5.......
0000 0020 bb5e e894 0000 0001 0000 0000 ... .^..........
0000 0001 0000 000d 544e 616d 6553 6572 ........TNameSer
7669 6365 0000 0000 0000 0004 0000 0000 vice............
0acd cdcd 0500 0000 6269 6e64 0000 cdcd ........bind....
0000 0000 0100 0000 0100 0000 0b00 0000 ................
464f 4f5f 4f42 4a45 4354 0000 0100 0000 FOO_OBJECT......
006d 672e 0c00 0000 4944 4c3a 466f 6f3a .mg.....IDL:Foo:
312e 3000 0100 0000 0000 0000 6800 0000 1.0.........h...
0101 0200 1000 0000 3139 352e 3137 312e ........195.171.
3231 362e 3132 3900 7a05 0000 0e00 0000 216.129.z.......
fe8c 25e2 3d00 000d 0000 0000 0000 0000 ..%.=...........
0200 0000 0000 0000 0800 0000 0100 0000 ................
0054 5441 0100 0000 1c00 0000 0100 0000 .TTA............
0100 0100 0100 0000 0100 0105 0901 0100 ................
0100 0000 0901 0100                     ........
omniORB: inputMessage: from giop:tcp:195.171.216.129:2809 97 bytes
4749 4f50 0102 0001 0000 0055 0000 0004 GIOP.......U....
0000 0001 0000 0001 4e45 4f00 0000 0002 ........NEO.....
000a 0000 0000 0000 0000 0035 4944 4c3a ...........5IDL:
6f6d 672e 6f72 672f 436f 734e 616d 696e omg.org/CosNamin
672f 4e61 6d69 6e67 436f 6e74 6578 742f g/NamingContext/
416c 7265 6164 7942 6f75 6e64 3a31 2e30 AlreadyBound:1.0
00                                      .
omniORB: sendChunk: to giop:tcp:195.171.216.129:2809 264 bytes
4749 4f50 0102 0100 fc00 0000 0600 0000 GIOP............
0300 0000 0000 cdcd 3500 0000 afab cb00 ........5.......
0000 0020 bb5e e894 0000 0001 0000 0000 ... .^..........
0000 0001 0000 000d 544e 616d 6553 6572 ........TNameSer
7669 6365 0000 0000 0000 0004 0000 0000 vice............
0acd cdcd 0700 0000 7265 6269 6e64 00cd ........rebind..
0000 0000 0100 0000 0100 0000 0b00 0000 ................
464f 4f5f 4f42 4a45 4354 0000 0100 0000 FOO_OBJECT......
006d 672e 0c00 0000 4944 4c3a 466f 6f3a .mg.....IDL:Foo:
312e 3000 0100 0000 0000 0000 6800 0000 1.0.........h...
0101 0200 1000 0000 3139 352e 3137 312e ........195.171.
3231 362e 3132 3900 7a05 0000 0e00 0000 216.129.z.......
fe8c 25e2 3d00 000d 0000 0000 0000 0000 ..%.=...........
0200 0000 0000 0000 0800 0000 0100 0000 ................
0054 5441 0100 0000 1c00 0000 0100 0000 .TTA............
0100 0100 0100 0000 0100 0105 0901 0100 ................
0100 0000 0901 0100                     ........
omniORB: inputMessage: from giop:tcp:195.171.216.129:2809 40 bytes
4749 4f50 0102 0001 0000 001c 0000 0006 GIOP............
0000 0000 0000 0001 4e45 4f00 0000 0002 ........NEO.....
000a 0000 0000 0000                     ........
omniORB: ObjRef() -- deleted.
FOO_OBJECT is now available!
[1]omniORB: Scan for idle connections (1038230929,159000000)
omniORB: Scavenger reduce idle count for strand 004628D0 to 23
omniORB: Scavenger reduce idle count for strand 00463EC0 to 23
omniORB: Scan for idle connections done (1038230929,159000000).
omniORB: Server accepted connection from giop:tcp:195.171.216.129:1407
omniORB: AsyncInvoker: thread id = 3 has started. Total threads = 3
omniORB: giopWorker task execute.
omniORB: Accepted connection from giop:tcp:195.171.216.129:1407 because of
this
rule: "* unix,ssl,tcp"
omniORB: inputMessage: from giop:tcp:195.171.216.129:1407 276 bytes
4749 4f50 0102 0000 0000 0108 0000 0007 GIOP............
0300 0000 0000 0000 0000 000e fe8c 25e2 ..............%.
3d00 000d 0000 0000 0000 0000 0000 0009 =...............
7374 6172 7449 6e74 0000 0000 0000 0003 startInt........
0000 0001 0000 000c 0000 0000 0001 0001 ................
0001 0109 4e45 4f00 0000 0002 000a 0000 ....NEO.........
0000 0006 0000 00a4 0000 0000 0000 0028 ...............(
4944 4c3a 6f6d 672e 6f72 672f 5365 6e64 IDL:omg.org/Send
696e 6743 6f6e 7465 7874 2f43 6f64 6542 ingContext/CodeB
6173 653a 312e 3000 0000 0001 0000 0000 ase:1.0.........
0000 0068 0001 0200 0000 0010 3139 352e ...h........195.
3137 312e 3231 362e 3132 3900 057e 0000 171.216.129..~..
0000 0019 afab cb00 0000 0002 bb62 bf55 .............b.U
0000 0008 0000 0000 0000 0000 0a00 0000 ................
0000 0001 0000 0001 0000 0020 0000 0000 ........... ....
0001 0001 0000 0002 0501 0001 0001 0020 ...............
0001 0109 0000 0001 0001 0100 0000 0000 ................
0000 004e                               ...N
omniORB:  recieve codeset service context and set TCS to
(ISO-8859-1,UTF-16)
::startInt() n=78
omniORB: sendChunk: to giop:tcp:195.171.216.129:1407 24 bytes
4749 4f50 0102 0101 0c00 0000 0700 0000 GIOP............
0000 0000 0000 0000                     ........
omniORB: inputMessage: from giop:tcp:195.171.216.129:1407 100 bytes
4749 4f50 0102 0000 0000 0058 0000 0008 GIOP.......X....
0300 0000 0000 0000 0000 000e fe8c 25e2 ..............%.
3d00 000d 0000 0000 0000 0000 0000 0009 =...............
7374 6172 7449 6e74 0000 0000 0000 0002 startInt........
0000 0001 0000 000c 0000 0000 0001 0001 ................
0001 0109 4e45 4f00 0000 0002 000a 0000 ....NEO.........
0000 004f                               ...O
omniORB:  recieve codeset service context and set TCS to
(ISO-8859-1,UTF-16)
::startInt() n=79
omniORB: sendChunk: to giop:tcp:195.171.216.129:1407 24 bytes
4749 4f50 0102 0101 0c00 0000 0800 0000 GIOP............
0000 0000 0000 0000                     ........
omniORB: inputMessage: from giop:tcp:195.171.216.129:1407 112 bytes
4749 4f50 0102 0000 0000 0064 0000 0009 GIOP.......d....
0300 0000 0000 0000 0000 000e fe8c 25e2 ..............%.
3d00 000d 0000 0000 0000 0000 0000 0009 =...............
7374 6172 7446 6f6f 0000 0000 0000 0002 startFoo........
0000 0001 0000 000c 0000 0000 0001 0001 ................
0001 0109 4e45 4f00 0000 0002 000a 0000 ....NEO.........
0000 000c feff 0048 0065 006c 006c 006f .......H.e.l.l.o
omniORB:  recieve codeset service context and set TCS to
(ISO-8859-1,UTF-16)
::startFoo() msg=
omniORB: sendChunk: to giop:tcp:195.171.216.129:1407 24 bytes
4749 4f50 0102 0101 0c00 0000 0900 0000 GIOP............
0000 0000 0000 0000                     ........
omniORB: AsyncInvoker: thread id = 4 has started. Total threads = 4
omniORB: giopWorker task execute.
omniORB: throw giopStream::CommFailure from
giopStream.cc:812(0,NO,COMM_FAILURE_
UnMarshalArguments)

As you can see, I call two times startInt and everything works fine, but
when I call startFoo, passing the wstring, I get the problem.

Thanks

Giuseppe