Commit ff300cf5 authored by Sven Neumann's avatar Sven Neumann Committed by Sven Neumann

configure.in allocate shared memory segments with permissions 0600 instead

2002-06-13  Sven Neumann  <sven@gimp.org>

	* configure.in
	* app/plug-in/plug-in.c (plug_in_init_shm): allocate shared memory
	segments with permissions 0600 instead of making them accessible
	by everyone.
parent 05f3910d
2002-06-13 Sven Neumann <sven@gimp.org>
* configure.in
* app/plug-in/plug-in.c (plug_in_init_shm): allocate shared memory
segments with permissions 0600 instead of making them accessible
by everyone.
2002-06-12 Sven Neumann <sven@gimp.org>
* app/paint/gimppaintcore.[ch]: applied a patch from Henning
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -192,8 +192,10 @@ plug_in_init_shm (void)
*/
#ifdef HAVE_SHM_H
shm_ID = shmget (IPC_PRIVATE, TILE_WIDTH * TILE_HEIGHT * 4, IPC_CREAT | 0777);
shm_ID = shmget (IPC_PRIVATE,
TILE_WIDTH * TILE_HEIGHT * 4,
IPC_CREAT | 0600);
if (shm_ID == -1)
g_message ("shmget() failed: Disabling shared memory tile transport.");
else
......
......@@ -411,7 +411,7 @@ if test "$ac_cv_header_sys_shm_h" = "yes"; then
{
int id;
char *shmaddr;
id = shmget (IPC_PRIVATE, 4, IPC_CREAT | 0777);
id = shmget (IPC_PRIVATE, 4, IPC_CREAT | 0600);
if (id == -1)
exit (2);
shmaddr = shmat (id, 0, 0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment