[gnome-games] all: Only call setgid_io_init() when --enable-setgid



commit 897b3b17429b27c4993c82f3fc72f56dd791f1c7
Author: Christian Persch <chpe gnome org>
Date:   Sat Jul 11 16:34:36 2009 +0200

    all: Only call setgid_io_init() when --enable-setgid

 glines/glines.c         |    2 ++
 gnibbles/main.c         |    2 ++
 gnobots2/gnobots.c      |    2 ++
 gnometris/main.cpp      |    2 ++
 gnomine/gnomine.c       |    2 ++
 gnotravex/gnotravex.c   |    2 ++
 gnotski/gnotski.c       |    2 ++
 gtali/gyahtzee.c        |    2 ++
 mahjongg/mahjongg.c     |    2 ++
 same-gnome/same-gnome.c |    2 ++
 10 files changed, 20 insertions(+), 0 deletions(-)
---
diff --git a/glines/glines.c b/glines/glines.c
index 1ae59c3..325db6c 100644
--- a/glines/glines.c
+++ b/glines/glines.c
@@ -1784,7 +1784,9 @@ main (int argc, char *argv[])
   if (!games_runtime_init ("glines"))
     return 1;
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   rgen = g_rand_new ();
 
diff --git a/gnibbles/main.c b/gnibbles/main.c
index f93e767..7642205 100644
--- a/gnibbles/main.c
+++ b/gnibbles/main.c
@@ -1030,7 +1030,9 @@ main (int argc, char **argv)
   if (!games_runtime_init ("gnibbles"))
     return 1;
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   context = g_option_context_new (NULL);
 
diff --git a/gnobots2/gnobots.c b/gnobots2/gnobots.c
index 85e0a56..3c804e5 100644
--- a/gnobots2/gnobots.c
+++ b/gnobots2/gnobots.c
@@ -212,7 +212,9 @@ main (int argc, char *argv[])
   gettimeofday (&tv, NULL);
   srand (tv.tv_usec);
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   context = g_option_context_new (NULL);
 #if GLIB_CHECK_VERSION (2, 12, 0)
diff --git a/gnometris/main.cpp b/gnometris/main.cpp
index fb82c48..37853ca 100644
--- a/gnometris/main.cpp
+++ b/gnometris/main.cpp
@@ -37,7 +37,9 @@ main(int argc, char *argv[])
 	if (!games_runtime_init ("gnometris"))
 		return 1;
 
+#ifdef ENABLE_SETGID
 	setgid_io_init ();
+#endif
 
 	int cmdlineLevel = 0;
 
diff --git a/gnomine/gnomine.c b/gnomine/gnomine.c
index 8acf209..1296e9a 100644
--- a/gnomine/gnomine.c
+++ b/gnomine/gnomine.c
@@ -1005,7 +1005,9 @@ main (int argc, char *argv[])
   if (!games_runtime_init ("gnomine"))
     return 1;
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   context = g_option_context_new (NULL);
 #if GLIB_CHECK_VERSION (2, 12, 0)
diff --git a/gnotravex/gnotravex.c b/gnotravex/gnotravex.c
index 5ee8f69..b5c17ab 100644
--- a/gnotravex/gnotravex.c
+++ b/gnotravex/gnotravex.c
@@ -423,7 +423,9 @@ main (int argc, char **argv)
   if (!games_runtime_init ("gnotravex"))
     return 1;
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   context = g_option_context_new (NULL);
 #if GLIB_CHECK_VERSION (2, 12, 0)
diff --git a/gnotski/gnotski.c b/gnotski/gnotski.c
index cd9f54e..747cc4b 100644
--- a/gnotski/gnotski.c
+++ b/gnotski/gnotski.c
@@ -488,7 +488,9 @@ main (int argc, char **argv)
   if (!games_runtime_init ("gnotski"))
     return 1;
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   context = g_option_context_new (NULL);
 #if GLIB_CHECK_VERSION (2, 12, 0)
diff --git a/gtali/gyahtzee.c b/gtali/gyahtzee.c
index c7b9b22..15e9e0f 100644
--- a/gtali/gyahtzee.c
+++ b/gtali/gyahtzee.c
@@ -874,7 +874,9 @@ main (int argc, char *argv[])
   if (!games_runtime_init ("gtali"))
     return 1;
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   /* Reset all yahtzee variables before parsing args */
   YahtzeeInit ();
diff --git a/mahjongg/mahjongg.c b/mahjongg/mahjongg.c
index 8021824..a277e6b 100644
--- a/mahjongg/mahjongg.c
+++ b/mahjongg/mahjongg.c
@@ -1393,7 +1393,9 @@ main (int argc, char *argv[])
   if (!games_runtime_init ("mahjongg"))
     return 1;
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   context = g_option_context_new (NULL);
 #if GLIB_CHECK_VERSION (2, 12, 0)
diff --git a/same-gnome/same-gnome.c b/same-gnome/same-gnome.c
index 0d32879..58870e9 100644
--- a/same-gnome/same-gnome.c
+++ b/same-gnome/same-gnome.c
@@ -138,7 +138,9 @@ main (int argc, char *argv[])
   if (!games_runtime_init ("same-gnome"))
     return 1;
 
+#ifdef ENABLE_SETGID
   setgid_io_init ();
+#endif
 
   context = g_option_context_new (NULL);
 #if GLIB_CHECK_VERSION (2, 12, 0)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]