Delete the shm segment as soon as wine and X have attached it.

This commit is contained in:
Andrew Lewycky 2000-03-19 12:41:20 +00:00 committed by Alexandre Julliard
parent e63fdf10f2
commit e4c4651833
1 changed files with 2 additions and 1 deletions

View File

@ -3245,6 +3245,8 @@ extern BOOL X11DRV_XShmCreateImage(XImage** image, int width, int height, int bp
if (!XShmErrorFlag)
{
shmctl(shminfo->shmid, IPC_RMID, 0);
XSetErrorHandler(WineXHandler);
LeaveCriticalSection( &X11DRV_CritSection );
@ -3438,7 +3440,6 @@ void X11DRV_DIB_DeleteDIBSection(BITMAPOBJ *bmp)
TSXShmDetach (display, &(dib->shminfo));
XDestroyImage (dib->image);
shmdt (dib->shminfo.shmaddr);
shmctl (dib->shminfo.shmid, IPC_RMID, 0);
dib->shminfo.shmid = -1;
}
else