home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / windows / openloo / 4430 < prev    next >
Encoding:
Text File  |  1992-11-10  |  6.0 KB  |  222 lines

  1. Newsgroups: comp.windows.open-look
  2. Path: sparky!uunet!munnari.oz.au!uniwa!cujo!lynchh
  3. From: lynchh@cs.curtin.edu.au (Huw Lynch)
  4. Subject: XView 3.0 Patch to stop Irix 4.0.5 server hanging
  5. Message-ID: <lynchh.721406858@marsh>
  6. Keywords: Irix 4.0.5 XView 3.0 patch OsHasLocale
  7. Sender: news@cujo.curtin.edu.au (News Manager)
  8. Organization: Curtin University of Technology
  9. Date: Tue, 10 Nov 1992 14:47:38 GMT
  10. Lines: 210
  11.  
  12.  
  13. SUBJECT : XView 3.0 patch file that :
  14.  
  15.       1. stops XView 3.0 hanging Irix 4.0.5 servers for _all_ client
  16.              architectures.
  17.  
  18.       2. For architectures that do not have OsHasLocale defined as YES
  19.              in XView.cf it reads the resource files XView and <xv_app_name>
  20.          from the system app-defaults file.
  21.  
  22. This is not a patch specifically for Irix machines, all architectures should
  23. use it (especially those that are networked to Irix machines and those
  24. that do not have OsHasLocale defined).
  25.  
  26. Action 1 is activated _only_ when the server identifies itself as a
  27.     "Silicon Graphics" version 4 server. When the buggy server is
  28.     detected the -Wfsdb option is forced (which fixes the problem).
  29.  
  30. Action 2 is automatically activated and configured when OsHasLocale is 
  31.       defined as NO in config/XView.cf. Naturally the <xv_app_name>
  32.     resources are given priority over those in XView and both have
  33.     lower priority than the command line and defaults loaded on the
  34.     server.
  35.     
  36. Files affected :
  37.  
  38.     xview3/lib/libxview/server/server.c
  39.     xview3/config/XView.tmpl
  40.  
  41. To apply this patch do the following...
  42.  
  43. cd <top of the XView 3.0 distribution>
  44. patch -p -s < <this file>
  45.  
  46.  
  47. This patch must be applied after the 2 official patches (Patch-01 & Patch-02).
  48.  
  49.  
  50.  
  51. By,
  52.  
  53. Huw Lynch
  54. ----------------------------------------------------------------------------
  55. lynchh@pride.cs.curtin.edu.au
  56. huw@gaius.curtin.edu.au
  57.  
  58.  
  59. *** ./config/XView.tmpl.old    Mon Nov  9 17:17:21 1992
  60. --- ./config/XView.tmpl    Fri Nov  6 15:40:19 1992
  61. ***************
  62. *** 99,106 ****
  63. --- 99,109 ----
  64.                 MKDIRHIER = BourneShell BinDir/mkdirhier
  65.   #endif
  66.   
  67. + /* HUW */
  68.   #if OsHasLocale
  69.            LOCALE_DEFINES = -DOS_HAS_LOCALE
  70. + #else
  71. +          LOCALE_DEFINES = -DNO_LOCALE_APP_DIR=\"$(XAPPLOADDIR)\"
  72.   #endif
  73.   
  74.   #if OsHasMmap
  75.  
  76.  
  77.  
  78. *** ./lib/libxview/server/server.c.old    Thu Oct 29 12:25:35 1992
  79. --- ./lib/libxview/server/server.c    Mon Nov  9 13:29:31 1992
  80. ***************
  81. *** 36,41 ****
  82. --- 36,43 ----
  83.   #include <X11/Xatom.h>
  84.   #include <X11/Xresource.h>
  85.   
  86. + #include <xview/fullscreen.h>    /* HUW: For Irix 4.0.5 patch */
  87.   #define    LIB_LOCALE    "/lib/locale/"
  88.   
  89.   #ifdef _XV_DEBUG
  90. ***************
  91. *** 307,312 ****
  92. --- 309,337 ----
  93.       xv_default_display = (Display *)server->xdisplay;
  94.       first_server = TRUE;
  95.       }
  96. +     /* HUW 
  97. +        SGI Irix 4.0.5 patch.
  98. +     
  99. +        This patch will avoid hanging Irix 4.0.5 servers and will not affect
  100. +        any other kind of server.
  101. +        Other special cases for other architectures could be chained on the
  102. +        end of this if statement.
  103. +     */
  104. +      if (strcmp(ServerVendor(server->xdisplay),"Silicon Graphics") == 0) {
  105. +         if (VendorRelease(server->xdisplay) == 4) {
  106. +        /* We have to set no grab mode to avoid hangs */
  107. +        fullscreendebug = 1;
  108. +       }
  109. +      }
  110.       /*
  111.        * Now that a server connection has been established, initialize the
  112.        * defaults database. Note - This assumes that server_init will be called
  113. ***************
  114. *** 356,362 ****
  115.        * Merge cmdline options into database
  116.        * Note:
  117.        * For the first server object created, this is actually
  118. !      * done twice. Once in xv_parse_cmdline() (in xv_init) and
  119.        * once here.
  120.        *
  121.        * xv_merge_cmdline() has to be called in xv_parse_cmdline()
  122. --- 381,387 ----
  123.        * Merge cmdline options into database
  124.        * Note:
  125.        * For the first server object created, this is actually
  126. !      * done twice. Once in xv_parse_cmdline() (in xv_
  127.        * once here.
  128.        *
  129.        * xv_merge_cmdline() has to be called in xv_parse_cmdline()
  130. ***************
  131. *** 388,393 ****
  132. --- 413,419 ----
  133.       server->localedir = NULL;
  134.   
  135.   #ifdef OS_HAS_LOCALE
  136.       if (_xv_use_locale) {
  137.       int    lc_ctype_read = FALSE;
  138.   
  139. ***************
  140. *** 628,634 ****
  141.       server->numeric = "C";
  142.       server->timeformat = "C";
  143.       }
  144. ! #endif OS_HAS_LOCALE
  145.       /*
  146.        * End of Sundae buyback code replacement for 
  147.        *    defaults_load_db(filename);
  148. --- 654,715 ----
  149.       server->numeric = "C";
  150.       server->timeformat = "C";
  151.       }
  152. ! /* #endif OS_HAS_LOCALE */
  153. ! #else
  154. ! #ifdef NO_LOCALE_APP_DIR
  155. !     /* HUW */
  156. !     /* Our OS doesn't have a locale but we still want to load in the
  157. !            Xview system defaults and the application defaults. This is patch 
  158. !        loads in the files XView and the file in xv_app_name from the
  159. !        system app-defaults directory if they exist.
  160. !        Defaults in xv_app_name override those of specified in the XView
  161. !        file.
  162. !            Both are overridden by any loaded above (i.e. the command line and
  163. !        defaults loaded on the server using xrdb).  
  164. !          */
  165. !      /* Only application specific stuff if there is an app name given */
  166. !          if (xv_app_name) {
  167. !         /* Construct the file name */
  168. !             strcpy(filename, NO_LOCALE_APP_DIR);
  169. !             strcat(filename,"/");
  170. !             strcat(filename, xv_app_name);
  171. !         /* Load the application defaults if there are some */
  172. !             if (new_db = XrmGetFileDatabase(filename)) {
  173. !                XrmMergeDatabases(server->db,&new_db);
  174. !                server->db = new_db;
  175. !                defaults_rdb = server->db;
  176. !             }
  177. !          }
  178. !  
  179. !          /* Load the XView defaults */
  180. !          strcpy(filename,NO_LOCALE_APP_DIR);
  181. !      strcat(filename,"/XView");
  182. !      if (new_db = XrmGetFileDatabase(filename)) {
  183. !         XrmMergeDatabases(server->db,&new_db);
  184. !         server->db = new_db;
  185. !         defaults_rdb = server->db;
  186. !      }
  187. ! #endif /* NO_LOCALE_APP_DIR */
  188. ! #endif /* not def OS_HAS_LOCALE */
  189.       /*
  190.        * End of Sundae buyback code replacement for 
  191.        *    defaults_load_db(filename);
  192.