Home | History | Annotate | Download | only in test

Lines Matching refs:shm

39 #error Failed to find the right header for X11 MIT-SHM protocol definitions
51 #include <sys/shm.h>
74 XShmSegmentInfo shm;
79 printf("Creating %dx%d SHM pixmap\n", width, height);
86 shm.shmid = shmget(IPC_PRIVATE, 4096, IPC_CREAT | 0666);
87 if (shm.shmid == -1)
90 shm.shmaddr = shmat(shm.shmid, 0, 0);
91 if (shm.shmaddr == (char *) -1) {
92 shmctl(shm.shmid, IPC_RMID, NULL);
96 shm.readOnly = False;
97 XShmAttach(dpy, &shm);
99 memset(shm.shmaddr, 0xcc, 4096);
104 shm.shmaddr + 64, &shm, width, height, 24);
106 shmctl(shm.shmid, IPC_RMID, NULL);
128 _x_error_occurred = memcmp(shm.shmaddr, expected, 4096);
132 XShmDetach(dpy, &shm);
133 shmdt(shm.shmaddr);