summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorWilliam Jon McCann <mccann@jhu.edu>2007-10-04 22:25:28 +0000
committerWilliam Jon McCann <mccann@src.gnome.org>2007-10-04 22:25:28 +0000
commite2bf2da75482d853c5da54e4dc6b89d0596e68fa (patch)
tree03776231997a2ef2ab8900ae922e1f6422715466 /utils
parent14333ef1ffc4d2c5b162d2631c52ab71d88a2641 (diff)
downloadgdm-e2bf2da75482d853c5da54e4dc6b89d0596e68fa.tar.gz
Remove some more obsolete code. Move common code with unknown copyright
2007-10-04 William Jon McCann <mccann@jhu.edu> * common/Makefile.am: * common/gdm-common-unknown-origin.c: (gdm_sigchld_block_push), (gdm_sigchld_block_pop), (gdm_sigterm_block_push), (gdm_sigterm_block_pop), (gdm_sigusr2_block_push), (gdm_sigusr2_block_pop), (gdm_safe_fopen_w), (ve_clearenv): * common/gdm-common-unknown-origin.h: * common/gdm-common.c: * common/gdm-common.h: * config/Makefile.am: * config/XKeepsCrashing: * config/default.desktop.in: * config/extract-shell.sh: * config/gdmprefetchlist.in: * config/gettextfoo.h: * config/locale.alias: * config/ssh.desktop.in.in: * configure.ac: * daemon/Makefile.am: * daemon/choose.c: * daemon/choose.h: * daemon/gdm-xdmcp-display-factory.c: (gdm_xdmcp_handle_indirect_query), (gdm_xdmcp_handle_manage), (gdm_xdmcp_handle_managed_forward): * daemon/main.c: (delete_pid): * utils/Makefile.am: * utils/gdm-dmx-reconnect-proxy.c: Remove some more obsolete code. Move common code with unknown copyright status into separate file. Try to identify more copy with unknown copyright status. svn path=/branches/mccann-gobject/; revision=5340
Diffstat (limited to 'utils')
-rw-r--r--utils/Makefile.am16
-rw-r--r--utils/gdm-dmx-reconnect-proxy.c133
2 files changed, 0 insertions, 149 deletions
diff --git a/utils/Makefile.am b/utils/Makefile.am
index 19dc4201..cecb396f 100644
--- a/utils/Makefile.am
+++ b/utils/Makefile.am
@@ -32,22 +32,6 @@ EXTRA_DIST = \
gdm-safe-restart.in \
$(NULL)
-if DMX_SUPPORT
-bin_PROGRAMS = gdm-dmx-reconnect-proxy
-endif
-
-if DMX_SUPPORT
-gdm_dmx_reconnect_proxy_SOURCES = \
- gdm-dmx-reconnect-proxy.c
-
-gdm_dmx_reconnect_proxy_LDADD = \
- $(GLIB_LIBS) \
- $(X_EXTRA_LIBS) \
- $(X_LIBS) \
- -lX11 \
- $(DMX_LIBS)
-endif
-
CLEANFILES = \
$(NULL)
diff --git a/utils/gdm-dmx-reconnect-proxy.c b/utils/gdm-dmx-reconnect-proxy.c
deleted file mode 100644
index c3bab83e..00000000
--- a/utils/gdm-dmx-reconnect-proxy.c
+++ /dev/null
@@ -1,133 +0,0 @@
-/*
- * Copyright (C) 2005 Red Hat, Inc.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-#include "config.h"
-
-#include <stdlib.h>
-#include <locale.h>
-#include <glib.h>
-#include <glib/gi18n.h>
-
-#include <X11/Xlib.h>
-#include <X11/extensions/dmxext.h>
-
-static char *to_display = NULL;
-static char *backend_display = NULL;
-static char *to_authfile = NULL;
-static char *backend_authfile = NULL;
-
-static GOptionEntry options[] = {
- {
- "to", 0, 0, G_OPTION_ARG_STRING, &to_display,
- N_("DMX display to migrate to"),
- N_("DISPLAY")
- },
- {
- "display", 0, 0, G_OPTION_ARG_STRING, &backend_display,
- N_("Backend display name"),
- N_("DISPLAY")
- },
- {
- "to-authfile", 0, 0, G_OPTION_ARG_STRING, &to_authfile,
- N_("Xauthority file for destination display"),
- N_("AUTHFILE")
- },
- {
- "display-authfile", 0, 0, G_OPTION_ARG_STRING, &backend_authfile,
- N_("Xauthority file for backend display"),
- N_("AUTHFILE")
- },
- { NULL }
-};
-
-static Display *
-get_dmx_display (const char *display_name,
- const char *authfile)
-{
- Display *display;
- int event_base, error_base;
- const char *old_authfile;
-
- old_authfile = getenv ("XAUTHORITY");
- g_setenv ("XAUTHORITY", authfile, TRUE);
-
- if ((display = XOpenDisplay (display_name)) == NULL)
- g_printerr (_("Failed to open display \"%s\"\n"), display_name);
-
- if (display != NULL &&
- !DMXQueryExtension (display, &event_base, &error_base)) {
- g_printerr (_("DMX extension not present on \"%s\"\n"), display_name);
- XCloseDisplay (display);
- display = NULL;
- }
-
- g_setenv ("XAUTHORITY", old_authfile, TRUE);
-
- return display;
-}
-
-int
-main (int argc, char **argv)
-{
- GOptionContext *options_context;
- Display *display;
- DMXScreenAttributes attr;
- guint mask;
- int screen;
-
- setlocale (LC_ALL, "");
- bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);
- textdomain (GETTEXT_PACKAGE);
-
- options_context = g_option_context_new (_("- migrate a backend display from one DMX display to another"));
- g_option_context_add_main_entries (options_context, options, GETTEXT_PACKAGE);
- g_option_context_parse (options_context, &argc, &argv, NULL);
- g_option_context_free (options_context);
-
- if (to_display == NULL) {
- g_printerr (_("You must specify a destination DMX display using %s\n"), "--to");
- return 1;
- }
-
- if (backend_display == NULL) {
- g_printerr (_("You must specify a backend display by using %s\n"), "--display");
- return 1;
- }
-
- if ((display = get_dmx_display (to_display, to_authfile)) == NULL)
- return 1;
-
- /* Note, we have no way yet of using backend_authfile to ensure
- * that the DMX server can authenticate against the backend Xserver.
- * For now, we must disable access control on the backend server.
- */
-
- mask = 0;
- screen = 0;
- if (!DMXAddScreen (display, backend_display, mask, &attr, &screen)) {
- g_printerr (_("DMXAddScreen \"%s\" failed on \"%s\"\n"),
- backend_display, to_display);
- XCloseDisplay (display);
- return 1;
- }
-
- XCloseDisplay (display);
-
- return 0;
-}