IpcMemoryDetach(int status, Datum shmaddr)
{
/* Detach System V shared memory block. */
- if (shmdt(DatumGetPointer(shmaddr)) < 0)
+ if (shmdt((void *) DatumGetPointer(shmaddr)) < 0)
elog(LOG, "shmdt(%p) failed: %m", DatumGetPointer(shmaddr));
}
IpcMemoryState state;
state = PGSharedMemoryAttach((IpcMemoryId) id2, NULL, &memAddress);
- if (memAddress && shmdt(memAddress) < 0)
+ if (memAddress && shmdt((void *) memAddress) < 0)
elog(LOG, "shmdt(%p) failed: %m", memAddress);
switch (state)
{
break;
}
- if (oldhdr && shmdt(oldhdr) < 0)
+ if (oldhdr && shmdt((void *) oldhdr) < 0)
elog(LOG, "shmdt(%p) failed: %m", oldhdr);
}