rpms/gdm/devel gdm-2.23.92-force-active-vt.patch, 1.1, 1.2 gdm.spec, 1.412, 1.413

Ray Strode rstrode at fedoraproject.org
Fri Sep 12 16:22:06 UTC 2008


Author: rstrode

Update of /cvs/pkgs/rpms/gdm/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv31897

Modified Files:
	gdm-2.23.92-force-active-vt.patch gdm.spec 
Log Message:
- Fix bug in last patch


gdm-2.23.92-force-active-vt.patch:

Index: gdm-2.23.92-force-active-vt.patch
===================================================================
RCS file: /cvs/pkgs/rpms/gdm/devel/gdm-2.23.92-force-active-vt.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- gdm-2.23.92-force-active-vt.patch	11 Sep 2008 21:10:53 -0000	1.1
+++ gdm-2.23.92-force-active-vt.patch	12 Sep 2008 16:21:36 -0000	1.2
@@ -42,7 +42,7 @@
  	-DPIXMAPDIR=\"$(pixmapdir)\"			\
  	-DSBINDIR=\"$(sbindir)\"			\
  	-DGNOMELOCALEDIR=\""$(datadir)/locale"\"	\
-+	-DGDM_SPOOL_DIR=\"$(GDM_SPOOL_DIR)\"  \
++        -DGDM_SPOOL_DIR=\"$(GDM_SPOOL_DIR)\"  \
  	-DGDM_XAUTH_DIR=\"$(GDM_XAUTH_DIR)\"		\
  	-DGDM_DEFAULTS_CONF=\"$(GDM_DEFAULTS_CONF)\"	\
  	-DGDM_CUSTOM_CONF=\"$(GDM_CUSTOM_CONF)\"	\
@@ -66,51 +66,51 @@
 +static gboolean
 +should_force_display_on_active_vt (void)
 +{
-+	gboolean should_force_display_on_active_vt;
++        gboolean should_force_display_on_active_vt;
 +
-+	should_force_display_on_active_vt = g_file_test (GDM_SPOOL_DIR "/force-display-on-active-vt",
-+			               G_FILE_TEST_EXISTS);
-+  	g_unlink (GDM_SPOOL_DIR "/force-display-on-active-vt");
++        should_force_display_on_active_vt = g_file_test (GDM_SPOOL_DIR "/force-display-on-active-vt",
++                                                         G_FILE_TEST_EXISTS);
++        g_unlink (GDM_SPOOL_DIR "/force-display-on-active-vt");
 +
-+  	return should_force_display_on_active_vt;
++        return should_force_display_on_active_vt;
 +}
 +
 +static int
 +get_active_vt (void)
 +{
-+	int console_fd;
-+	struct vt_stat console_state = { 0 };
++        int console_fd;
++        struct vt_stat console_state = { 0 };
 +
-+	console_fd = open ("/dev/tty0", O_RDONLY | O_NOCTTY);
++        console_fd = open ("/dev/tty0", O_RDONLY | O_NOCTTY);
 +
-+	if (console_fd < 0) {
-+		goto out;
-+	}
-+
-+	if (ioctl (console_fd, VT_GETSTATE, &console_state) < 0) {
-+		goto out;
-+	}
++        if (console_fd < 0) {
++                goto out;
++        }
++
++        if (ioctl (console_fd, VT_GETSTATE, &console_state) < 0) {
++                goto out;
++        }
 +
 +out:
-+  	if (console_fd >= 0) {
-+    		close (console_fd);
-+	}
++        if (console_fd >= 0) {
++                close (console_fd);
++        }
 +
-+  return console_state.v_active;
++        return console_state.v_active;
 +}
 +
 +static char *
 +get_active_vt_as_string (void)
 +{
-+	int vt;
++        int vt;
 +
-+	vt = get_active_vt ();
-+	
-+	if (vt <= 0) {
-+		return NULL;
-+	}
++        vt = get_active_vt ();
 +
-+	return g_strdup_printf ("vt%d", vt);
++        if (vt <= 0) {
++                return NULL;
++        }
++
++        return g_strdup_printf ("vt%d", vt);
 +}
 +
  /**
@@ -122,18 +122,18 @@
  
 -        /* fork X server process */
 -        res = gdm_server_spawn (server, NULL);
-+	if (should_force_display_on_active_vt () || TRUE) {
++        if (should_force_display_on_active_vt ()) {
 +                char *vt;
 +
-+		g_free (server->priv->command);
-+		server->priv->command = g_strdup (X_SERVER " -nr -verbose");
++                g_free (server->priv->command);
++                server->priv->command = g_strdup (X_SERVER " -nr -verbose");
 +                vt = get_active_vt_as_string ();
-+		res = gdm_server_spawn (server, vt);
++                res = gdm_server_spawn (server, vt);
 +                g_free (vt);
-+	} else {
-+		/* fork X server process */
-+		res = gdm_server_spawn (server, NULL);
-+	}
++        } else {
++                /* fork X server process */
++                res = gdm_server_spawn (server, NULL);
++        }
  
          return res;
  }
@@ -153,7 +153,7 @@
  	-rf \
  	$(DESTDIR)$(workingdir)/.gconf.mandatory \
  	$(DESTDIR)$(xauthdir)
-+	$(DESTDIR)$(spooldir)
++        $(DESTDIR)$(spooldir)
  
  install-data-hook: gdm.conf-custom Xsession Init PostSession PreSession gconf.path
  	if test '!' -d $(DESTDIR)$(gdmconfdir); then \
@@ -161,11 +161,11 @@
  		chown root:gdm $(DESTDIR)$(workingdir) || : ; \
  	fi
  
-+	if test '!' -d $(DESTDIR)$(spooldir); then \
-+		$(mkinstalldirs) $(DESTDIR)$(spooldir); \
-+		chmod 1770 $(DESTDIR)$(spooldir); \
-+		chown root:gdm $(DESTDIR)$(spooldir) || : ; \
-+	fi
++        if test '!' -d $(DESTDIR)$(spooldir); then \
++        	$(mkinstalldirs) $(DESTDIR)$(spooldir); \
++        	chmod 1770 $(DESTDIR)$(spooldir); \
++        	chown root:gdm $(DESTDIR)$(spooldir) || : ; \
++        fi
 +
  	$(INSTALL_DATA) $(srcdir)/gconf.path $(DESTDIR)$(workingdir)/.gconf.path
  	gconftool-2 --direct --config-source=xml:merged:$(DESTDIR)$(workingdir)/.gconf.mandatory --recursive-unset /


Index: gdm.spec
===================================================================
RCS file: /cvs/pkgs/rpms/gdm/devel/gdm.spec,v
retrieving revision 1.412
retrieving revision 1.413
diff -u -r1.412 -r1.413
--- gdm.spec	11 Sep 2008 21:10:53 -0000	1.412
+++ gdm.spec	12 Sep 2008 16:21:36 -0000	1.413
@@ -16,7 +16,7 @@
 Summary: The GNOME Display Manager
 Name: gdm
 Version: 2.23.92
-Release: 3%{?dist}
+Release: 4%{?dist}
 Epoch: 1
 License: GPLv2+
 Group: User Interface/X
@@ -304,6 +304,9 @@
 %{_datadir}/gnome-2.0/ui/GNOME_FastUserSwitchApplet.xml
 
 %changelog
+* Fri Sep 12 2008 Ray Strode <rstrode at redhat.com> - 1:2.23.92-4
+- Fix bug in last patch
+
 * Thu Sep 11 2008 Ray Strode <rstrode at redhat.com> - 1:2.23.92-3
 - Add hook to allow for plymouth transition
 




More information about the fedora-extras-commits mailing list