Re: JacORB vs ORBit again
- From: Alejandro Imass <aimass aimass org>
- To: orbit-list gnome org
- Subject: Re: JacORB vs ORBit again
- Date: Fri, 22 Dec 2000 09:42:51 -0400
Paco Moya wrote:
> ORBit does not understand object references returned by method invocations
> to JacORB server (Big endian converting).
>
Hi. I just went through a similar experience and I found that JacORB was creating an UNEVEN number of bytes. Later I found that all IOR's should be of EVEN size.
It's ver easy to hack the ORBit code. In orb.c you will find the function CORBA_ORB_object_to_string(bla...)
here you will find a big switch and a for loop that decodes the string. just open a file here and start fprintf to see all the decision making in the switch, and you will come up with the answer quickly.
I included this right after all the variable declaratins in this function:
// The Brain Police
FILE * ofp;
char* retval2;
ofp = fopen("/home/aimass/libORBit-debug.txt","w");
fprintf(ofp,"*** Start of Debug File *** \n", retval2);
In my case it was one of the first checks (the EVEN check):
if((len % 2) || len <= 4) {
CORBA_exception_set_system(ev, ex_CORBA_MARSHAL,
CORBA_COMPLETED_NO);
// The Brain Police
fprintf(ofp,"Was NOT EVEN LEN \n", retval2);
return(CORBA_OBJECT_NIL);
}
Remember to close your file here:
// The Brain Police
fprintf(ofp,"Returning a supposedly valid retval \n", retval2);
retval = ORBit_create_object_with_info(profiles, type_id, orb, ev);
error_out:
// The Brain Police
fprintf(ofp,"Actual Return \n", retval2);
// The Brain Police
fclose(ofp);
return retval;
It is probably a very unexpert way to debug this but it solved my problem...
What I did was to recompile ORBit in my home directory and copied my hacked liORBit.so.0.4.0 (I'm using ORBit 0.5.3) to /usr/lib. Remember to back up your original lib first. I think if this is a common thing w/ JacORB, perhaps we should try to see if we can fix JacORB or let ORBit be more tolerant to JacORB IORs.
Best Regards,
Alejandro Imass
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]