gnome-terminal r3095 - branches/gnome-2-24/src



Author: chpe
Date: Thu Sep 25 18:48:19 2008
New Revision: 3095
URL: http://svn.gnome.org/viewvc/gnome-terminal?rev=3095&view=rev

Log:
Fix finding the display when the display name has no period in it.

Modified:
   branches/gnome-2-24/src/terminal.c

Modified: branches/gnome-2-24/src/terminal.c
==============================================================================
--- branches/gnome-2-24/src/terminal.c	(original)
+++ branches/gnome-2-24/src/terminal.c	Thu Sep 25 18:48:19 2008
@@ -932,8 +932,9 @@
         {
           GdkDisplay *disp = l->data;
 
-          /* compare without the screen number part */
-          if (strncmp (gdk_display_get_name (disp), display_name, period - display_name) == 0)
+          /* compare without the screen number part, if present */
+          if ((period && strncmp (gdk_display_get_name (disp), display_name, period - display_name) == 0) ||
+              (period == NULL && strcmp (gdk_display_get_name (disp), display_name) == 0))
             {
               display = disp;
               break;



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