home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / infosyst / gopher / 1145 next >
Encoding:
Text File  |  1992-11-15  |  7.7 KB  |  288 lines

  1. Path: sparky!uunet!pmafire!mica.inel.gov!ux1!news.byu.edu!eff!sol.ctr.columbia.edu!usc!rpi!batcomputer!munnari.oz.au!mel.dit.csiro.au!mineng.dmpe.CSIRO.AU!dmssyd.syd.dms.CSIRO.AU!metro!grivel!alsvid!mark
  2. From: mark@alsvid.une.edu.au (Mark Andrew Garrett)
  3. Newsgroups: comp.infosystems.gopher
  4. Subject: BUG in gopher1.1b1
  5. Message-ID: <Bxr5zA.Bx1@alsvid.une.edu.au>
  6. Date: 15 Nov 92 10:18:45 GMT
  7. Organization: University of New England - Northern Rivers (Lismore)
  8. Lines: 278
  9.  
  10. I've been try gopher1.1b1 + wais-8-b5 out on ultrix4.2 gcc2.3.1 (and gcc2.2.2)
  11.  
  12. I've added an extra secure mode Securemode == VERY
  13. which disallows the mail option as well for the client.
  14.  
  15. I've also been having crash problems with memory aborts.
  16. I've found at least on bug in the STRstring.c but not the one
  17. giving me crashes in side of STRinit()
  18.  
  19.     Here are my diffs for gopher and wais
  20. Any comments gratefully recieved.
  21.  
  22.         Cheers
  23.             Mark :)
  24.  
  25.  
  26. diff -cr gopher1.1b1-DIST/doc/gopher.1 gopher1.1b1/doc/gopher.1
  27. *** gopher1.1b1-DIST/doc/gopher.1    Sat Aug  1 03:34:16 1992
  28. --- gopher1.1b1/doc/gopher.1    Sun Nov 15 19:44:30 1992
  29. ***************
  30. *** 3,9 ****
  31.   gopher \- connect to gopher document server
  32.   .SH SYNOPSIS
  33.   .B gopher
  34. ! .RI [ -sb ]
  35.   .RI [ -t
  36.   .IR title]
  37.   .RI [ -p 
  38. --- 3,9 ----
  39.   gopher \- connect to gopher document server
  40.   .SH SYNOPSIS
  41.   .B gopher
  42. ! .RI [ -sSb ]
  43.   .RI [ -t
  44.   .IR title]
  45.   .RI [ -p 
  46. ***************
  47. *** 23,28 ****
  48. --- 23,31 ----
  49.   .PP
  50.   -s means "secure mode" which means that you can't save or print the
  51.   files that you browse.
  52. + .PP
  53. + -S means "very secure mode" which means that you can't save,  print or
  54. + mail the files that you browse.
  55.   .PP
  56.   -b starts the client on the bookmark page.
  57.   
  58. diff -cr gopher1.1b1-DIST/gopher/globals.h gopher1.1b1/gopher/globals.h
  59. *** gopher1.1b1-DIST/gopher/globals.h    Wed Oct 14 18:07:16 1992
  60. --- gopher1.1b1/gopher/globals.h    Sun Nov 15 19:40:12 1992
  61. ***************
  62. *** 79,81 ****
  63. --- 79,83 ----
  64.   int  Load_Index_or_Dir();
  65.   void GetOneOption(/* */);
  66.   void check_sock(/* int, char* */);
  67. + #define VERY (-1)
  68. Only in gopher1.1b1/gopher: globals.h-DIST
  69. Only in gopher1.1b1/gopher: globals.o
  70. Only in gopher1.1b1/gopher: gopher
  71.  
  72. diff -cr gopher1.1b1-DIST/gopher/gopher.c gopher1.1b1/gopher/gopher.c
  73. *** gopher1.1b1-DIST/gopher/gopher.c    Thu Nov  5 11:33:02 1992
  74. --- gopher1.1b1/gopher/gopher.c    Sun Nov 15 19:45:56 1992
  75. ***************
  76. *** 809,819 ****
  77.   
  78.        sTmp[0] = '\0';
  79.   
  80. !      while ((c = getopt(argc, argv, "Dsbp:t:")) != -1)
  81.         switch (c) {
  82.         case 's':
  83.              SecureMode = TRUE;
  84.              break;
  85.         case 'p':
  86.              GSsetPath(RootGophers[0], optarg);
  87.              GSsetPath(RootGophers[1], optarg);
  88. --- 809,822 ----
  89.   
  90.        sTmp[0] = '\0';
  91.   
  92. !      while ((c = getopt(argc, argv, "DsSbp:t:")) != -1)
  93.         switch (c) {
  94.         case 's':
  95.              SecureMode = TRUE;
  96.              break;
  97. +       case 'S':
  98. +            SecureMode = VERY;
  99. +            break;
  100.         case 'p':
  101.              GSsetPath(RootGophers[0], optarg);
  102.              GSsetPath(RootGophers[1], optarg);
  103. ***************
  104. *** 834,840 ****
  105.   
  106.   
  107.        if (errflag) {
  108. !       fprintf(stderr, "Usage: %s [-sb] [-p path] [-t title] [hostname port]+\n", argv[0]);
  109.         exit(-1);
  110.        }
  111.   
  112. --- 837,843 ----
  113.   
  114.   
  115.        if (errflag) {
  116. !       fprintf(stderr, "Usage: %s [-sSb] [-p path] [-t title] [hostname port]+\n", argv[0]);
  117.         exit(-1);
  118.        }
  119.   
  120. diff -cr gopher1.1b1-DIST/gopher/ourutils.c gopher1.1b1/gopher/ourutils.c
  121. *** gopher1.1b1-DIST/gopher/ourutils.c    Sat Oct 31 07:48:38 1992
  122. --- gopher1.1b1/gopher/ourutils.c    Sun Nov 15 19:31:25 1992
  123. ***************
  124. *** 131,138 ****
  125.   
  126.        if (!SecureMode)
  127.         printf(", <m> to mail, <s> to save, or <p> to print:");
  128. !      else
  129.         printf(", <m> to mail:");
  130.   
  131.        fflush(stdout);
  132.        noecho();
  133. --- 131,142 ----
  134.   
  135.        if (!SecureMode)
  136.         printf(", <m> to mail, <s> to save, or <p> to print:");
  137. !      else {
  138. !     if (SecureMode == VERY)
  139. !       printf(":");
  140. !     else
  141.         printf(", <m> to mail:");
  142. +      }
  143.   
  144.        fflush(stdout);
  145.        noecho();
  146. ***************
  147. *** 153,158 ****
  148. --- 157,163 ----
  149.              case ' ':
  150.               break;
  151.              case 'm':
  152. +           if (SecureMode != VERY)
  153.               mail_file(Filename, Realname);
  154.               break;
  155.   
  156. diff -cr gopher1.1b1-DIST/object/STRstring.c gopher1.1b1/object/STRstring.c
  157. *** gopher1.1b1-DIST/object/STRstring.c    Sat Oct 31 07:18:46 1992
  158. --- gopher1.1b1/object/STRstring.c    Sun Nov 15 20:48:32 1992
  159. ***************
  160. *** 18,24 ****
  161.        if (in == NULL)
  162.         return(temp);
  163.   
  164. !      len = strlen(in);
  165.   
  166.        temp->data = (char *) malloc(len * sizeof(char*));
  167.        strcpy(temp->data, in);
  168. --- 18,24 ----
  169.        if (in == NULL)
  170.         return(temp);
  171.   
  172. !      len = strlen(in) + 1; /* THIS WAS A BUG!allow for null termination.... */
  173.   
  174.        temp->data = (char *) malloc(len * sizeof(char*));
  175.        strcpy(temp->data, in);
  176. diff -cr gopher1.1b1-DIST/object/compatible.c gopher1.1b1/object/compatible.c
  177. *** gopher1.1b1-DIST/object/compatible.c    Sat Nov  7 05:21:39 1992
  178. --- gopher1.1b1/object/compatible.c    Thu Nov 12 04:54:26 1992
  179. ***************
  180. *** 9,19 ****
  181.   
  182.   /*** For machines that don't have strstr ***/
  183.   
  184. ! #if defined(NOSTRSTR) || defined(mips) || defined(sequent) || defined(n16)
  185.   
  186.   char *
  187.   strstr(host_name, cp)
  188. !   char host_name[256];
  189.     char *cp;
  190.   {
  191.        int i, j;
  192. --- 9,19 ----
  193.   
  194.   /*** For machines that don't have strstr ***/
  195.   
  196. ! #if defined(NOSTRSTR) || (defined(mips) && !defined(ultrix)) || defined(sequent) || defined(n16)
  197. + /* this was also a problem in 1.03 DEC mips have strstr and this wont compile */
  198.   char *
  199.   strstr(host_name, cp)
  200. ! char host_name[256];
  201.     char *cp;
  202.   {
  203.        int i, j;
  204.  
  205.  
  206. And the changes for WAIS-8-B5 .... diffs
  207.  
  208.  
  209. diff -cr wais-8-b5-DIST/ir/irretrvl.c wais-8-b5/ir/irretrvl.c
  210. *** wais-8-b5-DIST/ir/irretrvl.c    Mon May 11 07:43:57 1992
  211. --- wais-8-b5/ir/irretrvl.c    Sat Nov 14 21:00:41 1992
  212. ***************
  213. *** 76,88 ****
  214.   
  215.    */
  216.   
  217. ! #include "irretrvl.h"
  218.   #include "irfiles.h" /* for filename_table_ext */
  219.   #include <string.h>
  220. ! #include "futil.h"
  221.   #include <ctype.h>  /* for isspace */
  222. ! #include "irext.h"
  223. ! #include "irdirent.h"
  224.   #include <sys/stat.h>
  225.   
  226.   #ifdef Mach
  227. --- 76,89 ----
  228.   
  229.    */
  230.   
  231. ! #include "irretrvl.h" /* */
  232.   #include "irfiles.h" /* for filename_table_ext */
  233.   #include <string.h>
  234. ! #include "futil.h" /* */
  235.   #include <ctype.h>  /* for isspace */
  236. ! #include "irext.h" /* */
  237. ! #include "irdirent.h" /* */
  238. ! #include <sys/types.h> /* must include for ultrix gcc for stat.h */
  239.   #include <sys/stat.h>
  240.   
  241.   #ifdef Mach
  242. diff -cr wais-8-b5-DIST/ui/util.h wais-8-b5/ui/util.h
  243. *** wais-8-b5-DIST/ui/util.h    Wed Mar 18 08:29:40 1992
  244. --- wais-8-b5/ui/util.h    Sat Nov 14 21:39:28 1992
  245. ***************
  246. *** 17,24 ****
  247.   #define _H_UTIL
  248.   
  249.   #include <cdialect.h>
  250.   
  251. ! int charlistlength _AP((char** list));
  252. ! void listlength _AP((List list));
  253.   void find_value _AP((char* source, char* key, char* value, int value_size));
  254.   #endif
  255. --- 17,25 ----
  256.   #define _H_UTIL
  257.   
  258.   #include <cdialect.h>
  259. + #include <list.h>    /* MG attempt to keep gcc happy about listlength */
  260.   
  261. ! int charlistlength _AP((char ** list));
  262. ! /* void listlength _AP(( List list)); Now way could i get this to compile
  263. so its comment it out, everything works ok with our this profile */
  264.   void find_value _AP((char* source, char* key, char* value, int value_size));
  265.   #endif
  266. diff -cr wais-8-b5-DIST/x/qcommands.c wais-8-b5/x/qcommands.c
  267. *** wais-8-b5-DIST/x/qcommands.c    Fri May  8 07:51:26 1992
  268. --- wais-8-b5/x/qcommands.c    Sat Aug 22 18:30:12 1992
  269. ***************
  270. *** 386,392 ****
  271.   void
  272.   AddResponseToQuestion(w, closure, call_data)
  273.   Widget w;
  274. ! caddr_t closure, call_data;
  275.   {
  276.     int numdocs, document_number, i;
  277.     Question q = the_Question->q;
  278. --- 386,393 ----
  279.   void
  280.   AddResponseToQuestion(w, closure, call_data)
  281.   Widget w;
  282. ! /* caddr_t closure, call_data; */
  283. ! XtPointer closure, call_data; 
  284.   {
  285.     int numdocs, document_number, i;
  286.     Question q = the_Question->q;
  287.