Fix bug in eventRecord::init_record
Look up event handle /after/ the device init routine has been run, in case it modified the event name in VAL. That didn't used to be possible because constant links couldn't return strings.
This commit is contained in:
@@ -102,10 +102,11 @@ static long init_record(struct dbCommon *pcommon, int pass)
|
||||
recGblInitConstantLink(&prec->siml, DBF_USHORT, &prec->simm);
|
||||
recGblInitConstantLink(&prec->siol, DBF_STRING, &prec->sval);
|
||||
|
||||
prec->epvt = eventNameToHandle(prec->val);
|
||||
|
||||
if( (pdset=(struct eventdset *)(prec->dset)) && (pdset->init_record) )
|
||||
status=(*pdset->init_record)(prec);
|
||||
|
||||
prec->epvt = eventNameToHandle(prec->val);
|
||||
|
||||
return(status);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user