|
|
|
|||||
|
Exceptions cannot be unmarshalled on client
When implementing an ICE service I ran inon an odd bug. It seems that ICE is not able to transfer errors correctly over the boundary of a library, at least under certain circumstances.
Appending you will find a ZIP file with a simple test scenario. It contains a precompiled server.exe which does nothing than throwing a bug. Furthermore there is a client_ok.exe which catches the bug correctly and a client_ko.exe which throws an Ice::UnmarshalOutOfBoundsException. The only difference between client_ok.exe and client_ko.exe is that for client_ok.exe I removed the line #define SHOW_ICE_EXCEPTION_BUG from exceptions.ice. This made the exception appear in test.ice instead of exceptions.ice e voila - it works! I.M.H.O. it shouldn't matter in which .ice file an exception is defined as long as the generated .h / .cpp files are included correctly. Another way to "solve" the problem was to compile all the objects directly into the executables rather than using an intermedate library (interface.lib, see the included Makefile). This is really a weird bug and I hope you won't have too many problems to finally track it down. Though I have a workaround now it would be really nice if the bug could be removed in the next ICE version, so that I can tidy up my .ice files and more important, to safe others from this confusing phenomenon. I used ICE 1.5.1 on Windows XP with Microsoft Visual Studio .NET 7.0. I verified the bug with ICE 1.3.0 as well. It occurred with standalone servers and IceBox servers, with or without debug libraries alike. Last edited by robert : 10-15-2004 at 08:05 AM. |
|
|||||
|
Insert an ordered list into your message
Hello Bernard,
I'm really sorry, I appended the wrong test scenario. Hereby I send the correct one. I do indeed use static libraries and yes, it's very odd. Hope bug hunting means fun to you :-). Best Regards Robert. |
|
||||||
|
Hi Robert
I confirm this is a bug with Ice exception-factory registration. We'll try to fix it before the next release (1.6)! Thanks for the bug report and test case. Bernard |
|
||||||
|
I've posted a patch at Patch for slice2cpp, release 1.5.1. Thanks for reporting this bug!
Cheers, Michi. |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| C# exceptions | wrobbie | Help Center | 7 | 09-25-2005 07:03 PM |
| Catching Exceptions | chuatecksiong | Help Center | 3 | 04-06-2005 01:02 PM |
| Classes vs. Exceptions | andreynech | Comments | 7 | 02-28-2003 10:12 AM |
| Exceptions and the ice_throw function | marlowa | Help Center | 2 | 02-28-2003 07:37 AM |