I don't have much experience with the C api so I don't know how much I can help on this. I take it that you are running an agent (LS or Java?) and that you are making this C api calls in the agent? Can you post the rest of the code so I/others can see what exactly it is trying to do?