Thanks Edward,<br><br>i see the problem but i have the problem also if i have this function:<br> <br> void inter2::getName( prova::inter_ptr obj )<br>
{<br>
char *p=obj->name();<br>
<br>
cout<<p<<endl;<br>
}<br><br><br><div class="gmail_quote">2010/1/21 Edward Lin <span dir="ltr"><<a href="http://edwardlin.tw">edwardlin.tw</a>@<a href="http://gmail.com">gmail.com</a>></span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br>
<br>
At least I see one problem, you cannot "return p"; you must<br>
<br>
char* inter2::getName( ... )<br>
{<br>
...<br>
return CORBA::string_dup(p);<br>
}<br>
<br>
You can refer to omniORB 'echo' example.<br>
<div><div></div><div class="h5"><br>
>> server:<br>
>><br>
>> char * inter2::getName( prova::inter_ptr obj )<br>
>> {<br>
>> char *p=obj->name();<br>
>><br>
>> cout<<p<<endl<br>
>><br>
>> return p;<br>
>> }<br>
</div></div></blockquote></div><br>