Hello CrystalSpace,
I have a method within a plugin that returns a csPtr<iParameter>. When I
call this method from another plugin assigning the output to a
csRef<iParameter> I get an "Assertion Failed: obj == <T*>CS_VOIDED_PTR"
error, but when I copy the same method into the plugin I am calling it
from I get no such error on the assignment.
The method called is:
csPtr<iParameter> celParameterManager::GetParameter (
const celParams& params,
const char* param)
{
printf("INSIDE\n");
return new celConstantParameter
}
And the declaration of the class returned is:
class celConstantParameter : public scfImplementation1<celConstantParameter,
iParameter>
{
private:
celData data;
csString str; // This string is used to hold temporary conversion to
string.
public:
celConstantParameter () : scfImplementationType (this) { }
celConstantParameter (const char* c) : scfImplementationType (this)
{
data.Set (c);
}
virtual ~celConstantParameter () { }
// From iParamater
virtual const celData* GetData (iCelParameterBlock*)
{
return &data;
}
virtual const char* Get (iCelParameterBlock*);
virtual const char* Get (iCelParameterBlock*, bool& changed)
{
changed = false;
return Get (0);
}
virtual int32 GetLong (iCelParameterBlock*);
};
Any suggestions as to where the problem may be rising are greatly
appreciated.
Kind Regards, Sam
------------------------------------------------------------------------------
_______________________________________________
Crystal-main mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/crystal-main
Unsubscribe:
mailto:[email protected]?subject=unsubscribe