From: peterson@choctaw.csc.ti.com (Bob Peterson)
Subject: Gopher 1.02 problems
Reply-To: peterson@csc.ti.com
Organization: TI Computer Science Laboratory
Date: Tue, 18 Aug 1992 19:35:22 GMT

  While installing Gopher 1.02 I encountered some anomolies.

  In gopherd/gopherd.c several calls to ropen and uopen use only two
parameters.  As declared in gopherd/openers.c, these functions actually
require three.  Also in gopherd/gopherd.c an "else" seems to be missing
near line 1535.  I appended context diffs to this message.

  Under Gopher 1.01 I implemented access to a local Archie server.  To
implement Archie access I modified Mike Macgirvin's shell script
examples (see his article <mtm.711060422@CAMIS>, posted on 13 Jul 92).
The scripts provide access to the command line Archie client.  However,
under Gopher 1.02 the scripts fail, apparently forcing the server into
an infinite loop.  Unless someone else knows the solution, I'll
continue working this problem.

    Bob

--
Bob Peterson             Work: peterson@csc.ti.com              Expressway Site
Texas Instruments        Home: peterson@zgnews.lonestar.org     North Building
P.O. Box 655474, MS238   TIMSG: RWP  Landline: +1 214 995 6080  Aisle A4
Dallas, Tx USA 75265                 FAX line: +1 214 995 0304  2-88V97


*** gopherd.c   Tue Aug 18 13:45:59 1992
--- gopherd.c.orig      Tue Aug 18 13:47:18 1992
***************
*** 1127,1133 ****
  
          /*** Test and see if the thing exists... and is readable ***/
          
!         if ((Zefilefd = ropen(filename, O_RDONLY, 0)) < 0) {
               *ObjType = "3";
               return;
          }
--- 1127,1133 ----
  
          /*** Test and see if the thing exists... and is readable ***/
          
!         if ((Zefilefd = ropen(filename, O_RDONLY)) < 0) {
               *ObjType = "3";
               return;
          }
***************
*** 1268,1274 ****
               /*** This is a link file, let's process it ***/
               int linkfd;
  
!              linkfd = uopen(filename, O_RDONLY, 0);
  
               if (linkfd >0) {
                    GDfromLink(SortDir, linkfd, Zehostname, GopherPort);
--- 1268,1274 ----
               /*** This is a link file, let's process it ***/
               int linkfd;
  
!              linkfd = uopen(filename, O_RDONLY);
  
               if (linkfd >0) {
                    GDfromLink(SortDir, linkfd, Zehostname, GopherPort);
***************
*** 1348,1354 ****
       if (UsingHTML)  {
          int aboutfd;
  
!         aboutfd = uopen(".about.html", O_RDONLY, 0);
          if (aboutfd > 0) {
               while (readline(aboutfd, newpath, 512))
                    writestring(sockfd, newpath);
--- 1348,1354 ----
       if (UsingHTML)  {
          int aboutfd;
  
!         aboutfd = uopen(".about.html", O_RDONLY);
          if (aboutfd > 0) {
               while (readline(aboutfd, newpath, 512))
                    writestring(sockfd, newpath);
***************
*** 1377,1383 ****
               if (UsingHTML) {
                    int aboutfd; 
  
!                   aboutfd = uopen(".about.html", O_RDONLY, 0);
                    if (aboutfd > 0) {
                         while (readline(aboutfd, newpath, 512))
                              writestring(cachefd, newpath);
--- 1377,1383 ----
               if (UsingHTML) {
                    int aboutfd; 
  
!                   aboutfd = uopen(".about.html", O_RDONLY);
                    if (aboutfd > 0) {
                         while (readline(aboutfd, newpath, 512))
                              writestring(cachefd, newpath);
***************
*** 1532,1538 ****
  
       if (startbyte != 0)
          fseek(ZeFile, startbyte, 0);
!      else /* rwp 18Aug92 */
       {
          FILE *pp;
          if (pp = specialfile(ZeFile, pathname)) {
--- 1532,1538 ----
  
       if (startbyte != 0)
          fseek(ZeFile, startbyte, 0);
! 
       {
          FILE *pp;
          if (pp = specialfile(ZeFile, pathname)) {