|
|
|
|||||
|
C#: callback (ice_response) problem
I am getting a null pointer exception in the C# generated code when ice_response is called in an async dispatch situation.
The relevant Slice is: Code:
struct Prop {
int Index;
Ice::ByteSeq Value;
};
sequence<Prop> PropSeq;
interface Store {
. . .
["ami", "amd"] idempotent
PropSeq Get(Ice::ByteSeq key, Ice::IntSeq propIndexes) throws ServiceError;
. . .
};
(I have marked the problem spot with a comment) Code:
class _AMD_Store_Get : IceInternal.IncomingAsync, AMD_Store_Get
{
public _AMD_Store_Get(IceInternal.Incoming inc) : base(inc)
{
}
public void ice_response(Services.StorageServices.Prop[] ret__)
{
try
{
IceInternal.BasicStream os__ = this.os__();
if(ret__ == null)
{
os__.writeSize(0);
}
else
{
os__.writeSize(ret__.Length);
for(int ix__ = 0; ix__ < ret__.Length; ++ix__)
{
ret__[ix__].write__(os__); // issue here
}
}
}
catch(Ice.LocalException ex__)
{
ice_exception(ex__);
}
response__(true);
}
public void ice_exception(_System.Exception ex)
{
try
{
throw ex;
}
catch(Services.ServiceError ex__)
{
os__().writeUserException(ex__);
response__(false);
}
catch(_System.Exception ex__)
{
exception__(ex__);
}
}
}
Karl |
|
||||||
|
Hi Karl,
I've posted a patch for the problem. Thanks for reporting this! You need to apply the patch to cpp/src/Slice/CsUtil.cpp, rebuild slice2cs, and recompile your Slice definitions. Cheers, Michi. |
|
|||||
|
Quote:
|
![]() |
| 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 |
| Help! Why ice_response for AMD block? | soloman817 | Help Center | 9 | 11-05-2007 01:03 PM |
| Multiple ice_response to a single AMI callback | kishore | Help Center | 3 | 06-05-2007 11:08 PM |
| demo/ice/callback problem | Rerox | Help Center | 1 | 07-27-2005 05:54 PM |
| demo/glacier2/callback problem | alienwolf | Help Center | 1 | 05-30-2005 12:52 AM |
| Callback sample problem | zhangzq71 | Help Center | 3 | 05-08-2005 10:04 AM |