X11: I don't want random local users accessing my videos!
authorRémi Denis-Courmont <remi@remlab.net>
Wed, 8 Jul 2009 20:11:51 +0000 (23:11 +0300)
committerRémi Denis-Courmont <remi@remlab.net>
Wed, 8 Jul 2009 20:15:24 +0000 (23:15 +0300)
(cherry picked from commit 0e4d1695919d4fe47e18e0708825508f9abc68c6)

modules/video_output/x11/xcommon.c

index 90de2f3..1947d21 100644 (file)
@@ -2920,9 +2920,8 @@ IMAGE_TYPE * CreateShmImage( vout_thread_t *p_vout,
         return NULL;
     }
 
         return NULL;
     }
 
-    /* Allocate shared memory segment - 0776 set the access permission
-     * rights (like umask), they are not yet supported by all X servers */
-    p_shm->shmid = shmget( IPC_PRIVATE, DATA_SIZE(p_image), IPC_CREAT | 0776 );
+    /* Allocate shared memory segment. */
+    p_shm->shmid = shmget( IPC_PRIVATE, DATA_SIZE(p_image), IPC_CREAT | 0600 );
     if( p_shm->shmid < 0 )
     {
         msg_Err( p_vout, "cannot allocate shared image data (%m)" );
     if( p_shm->shmid < 0 )
     {
         msg_Err( p_vout, "cannot allocate shared image data (%m)" );