]> Dogcows Code - chaz/openbox/commitdiff
Change setenv and unsetenv to putenv for portability.
authorMikael Magnusson <mikachu@comhem.se>
Thu, 18 Oct 2007 06:21:53 +0000 (08:21 +0200)
committerMikael Magnusson <mikachu@comhem.se>
Thu, 18 Oct 2007 06:25:34 +0000 (08:25 +0200)
Solaris apparently does not have setenv and unsetenv.

openbox/openbox.c
openbox/startupnotify.c

index 06afffc8264cf31b0daa5eb61b07cac5d7ffd5a5..77bb036305c58f9b535b5e822cfd01795aa294f3 100644 (file)
@@ -511,7 +511,7 @@ static void remove_args(gint *argc, gchar **argv, gint index, gint num)
 static void parse_env()
 {
     /* unset this so we don't pass it on unknowingly */
-    unsetenv("DESKTOP_STARTUP_ID");
+    putenv("DESKTOP_STARTUP_ID");
 }
 
 static void parse_args(gint *argc, gchar **argv)
index 002bd2dc0521991af7dd9b9b73d9f2de06003eba..4c929e7eaf12c786e31fd10895f5acaef009a4c7 100644 (file)
@@ -61,7 +61,7 @@ void sn_startup(gboolean reconfig)
     if (reconfig) return;
 
     /* unset this so we don't pass it on unknowingly */
-    unsetenv("DESKTOP_STARTUP_ID");
+    putenv("DESKTOP_STARTUP_ID");
 
     sn_display = sn_display_new(ob_display, NULL, NULL);
     sn_context = sn_monitor_context_new(sn_display, ob_screen,
@@ -259,7 +259,7 @@ void sn_setup_spawn_environment(gchar *program, gchar *name,
                              g_direct_equal,
                              (GDestroyNotify)sn_launcher_context_unref);
 
-    setenv("DESKTOP_STARTUP_ID", id, TRUE);
+    putenv(g_strdup_printf("DESKTOP_STARTUP_ID=%s", id));
 
     g_free(desc);
 }
This page took 0.023642 seconds and 4 git commands to generate.