seg-fault in ReplyError because sender is -1
Brought to you by:
bobfcsoft,
johnfcsoft
Anton Wilson
10-28-03
anton.wilson@camotion.com
In /simplipc/srd/simpl.c in Receive():
*sender = shmat(fifoMsg->shmid, 0, 0);
if (*sender == (char *)-1)
{
_simpl_setErrorCode(CANNOT_ATTACH_SHMEM,
taskStuff);
_simpl_log(taskStuff, "%s: cannot attach to
shmem-%s\n", fn, strerror(errno));
ReplyError(*sender, taskStuff);
return(-1);
in ReplyError(), the sender var is dereferenced,
causing a segfault in /simplipc/src/simplUtils for the
sprintf() call.