home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / misc / volume39 / ncftp / patch02 < prev    next >
Encoding:
Text File  |  1993-08-30  |  6.3 KB  |  187 lines

  1. Newsgroups: comp.sources.misc
  2. From: mgleason@cse.unl.edu (Mike Gleason)
  3. Subject: v39i068:  ncftp - Alternative User Interface for FTP, v1.5.0, Patch02
  4. Message-ID: <1993Aug30.211247.19711@sparky.sterling.com>
  5. X-Md4-Signature: 336c9e2bcd437e0951fdd8fe72458d7f
  6. Sender: kent@sparky.sterling.com (Kent Landfield)
  7. Organization: NCEMRSoft
  8. Date: Mon, 30 Aug 1993 21:12:47 GMT
  9. Approved: kent@sparky.sterling.com
  10.  
  11. Submitted-by: mgleason@cse.unl.edu (Mike Gleason)
  12. Posting-number: Volume 39, Issue 68
  13. Archive-name: ncftp/patch02
  14. Environment: UNIX, ANSI-C, !SVR4
  15. Patch-To: ncftp: Volume 39, Issue 53-57
  16.  
  17. This is the second official patch to ncftp 1.5. 
  18.  
  19. This patch fixes another termcap problem where boldface, etc, were not getting
  20. turned off correctly, and fixes a bug in the .netrc parsing code.
  21.  
  22. NcFTP 1.5.0 was posted last week to comp.sources.misc; you'll need that
  23. code with patch 1 applied for this patch to work.
  24.  
  25. diff -c ./README ../ncftp152/README
  26. *** ./README    Sun Aug 29 22:14:06 1993
  27. --- ../ncftp152/README    Mon Aug 30 14:57:44 1993
  28. ***************
  29. *** 93,98 ****
  30. --- 93,100 ----
  31.         gcc (set CC=gcc in the Makefile), or acc (set CC=acc).
  32.         The regular 'cc' is not an ANSI compiler.  You could also run
  33.         something like 'ansi2knr' on the sources and hope it works.
  34. +       You will probably need to link both the curses and termcap
  35. +       libraries if you use -DCURSES (see below).
  36.   
  37.       Hewlett-Packard HP-UX:  If you have 7.0, you'll need to find
  38.         a copy of <ftp.h> from somewhere (8.0 has it though). Then
  39. ***************
  40. *** 185,191 ****
  41.   *   -DCURSES:  Uses curses library to display boldface, underline, etc.
  42.       By default ncftp uses hard-coded ANSI escapes (^[[1m etc.) to
  43.       save the 100k or so the curses library adds.  You will also need
  44. !     to edit the LIBS line in the Makefile to add -lcurses.
  45.   
  46.   *   -DSYSLOG:  Define this to have ncftp log connections and transfers
  47.       to the syslog.
  48. --- 187,194 ----
  49.   *   -DCURSES:  Uses curses library to display boldface, underline, etc.
  50.       By default ncftp uses hard-coded ANSI escapes (^[[1m etc.) to
  51.       save the 100k or so the curses library adds.  You will also need
  52. !     to edit the LIBS line in the Makefile to add -lcurses.  You may
  53. !     need to add -ltermcap instead, or both -lcurses and -ltermcap.
  54.   
  55.   *   -DSYSLOG:  Define this to have ncftp log connections and transfers
  56.       to the syslog.
  57. diff -c ./ftprc.c ../ncftp152/ftprc.c
  58. *** ./ftprc.c    Sun Aug 29 22:14:05 1993
  59. --- ../ncftp152/ftprc.c    Mon Aug 30 14:57:45 1993
  60. ***************
  61. *** 450,456 ****
  62.                       cp++;
  63.               } else
  64.                   continue;
  65. !             if (strstr(host, str) != NULL) {
  66.                   site_found = 1;
  67.                   while (!isspace(*cp))
  68.                       ++cp;        /* skip the site name. */
  69. --- 450,457 ----
  70.                       cp++;
  71.               } else
  72.                   continue;
  73. !             /* if (strstr(cp, host) != NULL) { */
  74. !             if (strncmp(host, cp, strlen(host)) == 0) {
  75.                   site_found = 1;
  76.                   while (!isspace(*cp))
  77.                       ++cp;        /* skip the site name. */
  78. diff -c ./main.c ../ncftp152/main.c
  79. *** ./main.c    Sun Aug 29 22:14:05 1993
  80. --- ../ncftp152/main.c    Mon Aug 30 14:57:45 1993
  81. ***************
  82. *** 8,14 ****
  83.   #define _main_c_
  84.   
  85.   #define FTP_VERSION \
  86. ! "NcFTP 1.5.1 (Aug 29, 1993) by Mike Gleason, NCEMRSoft."
  87.   
  88.   /* #define BETA 1 */ /* If defined, it prints a little warning message. */
  89.   
  90. --- 8,14 ----
  91.   #define _main_c_
  92.   
  93.   #define FTP_VERSION \
  94. ! "NcFTP 1.5.2 (Aug 30, 1993) by Mike Gleason, NCEMRSoft."
  95.   
  96.   /* #define BETA 1 */ /* If defined, it prints a little warning message. */
  97.   
  98. ***************
  99. *** 1009,1015 ****
  100.       if (tgetent(tcbuf,term) != 1) {
  101.           (void) fprintf(stderr,"Can't get termcap entry for terminal [%s]\n", term);
  102.       } else {
  103. !         termcap_get(&tcap_normal, "se");
  104.           termcap_get(&tcap_boldface, "md");
  105.           termcap_get(&tcap_underline, "us");
  106.           termcap_get(&tcap_reverse, "so");
  107. --- 1009,1015 ----
  108.       if (tgetent(tcbuf,term) != 1) {
  109.           (void) fprintf(stderr,"Can't get termcap entry for terminal [%s]\n", term);
  110.       } else {
  111. !         termcap_get(&tcap_normal, "me");
  112.           termcap_get(&tcap_boldface, "md");
  113.           termcap_get(&tcap_underline, "us");
  114.           termcap_get(&tcap_reverse, "so");
  115. Only in ../ncftp152: ncftp
  116. diff -c ./open.c ../ncftp152/open.c
  117. *** ./open.c    Sun Aug 29 22:14:05 1993
  118. --- ../ncftp152/open.c    Mon Aug 30 14:57:45 1993
  119. ***************
  120. *** 436,441 ****
  121. --- 436,456 ----
  122.       char *user, *pass, *acct;    
  123.       int                    login_verbosity;
  124.   
  125. +     /* If the hostname supplied was an abbreviation, such as just
  126. +      * "wu" (wuarchive.wustl.edu), look through the list of sites
  127. +      * we know about and get the whole name.  We also would like
  128. +      * the path we want to start out in, if it is available.
  129. +      */
  130. +     GetFullSiteName(openopt->hostname, openopt->cdpath);
  131. + #ifdef GATEWAY
  132. +     /* Make sure the gateway host name is a full name and not an
  133. +      * abbreviation.
  134. +      */
  135. +     if (*gateway)
  136. +         GetFullSiteName(gateway, NULL);
  137. + #endif
  138.       ruser = rpass = racct = NULL;
  139.       /* This also loads the init macro. */
  140.       siteInRC = ruserpass2(openopt->hostname, &ruser, &rpass, &racct);
  141. ***************
  142. *** 471,491 ****
  143.        */
  144.       if (CheckForColonMode(openopt, &login_verbosity) == USAGE)
  145.           return USAGE;
  146. - #ifdef GATEWAY
  147. -     /* Make sure the gateway host name is a full name and not an
  148. -      * abbreviation.
  149. -      */
  150. -     if (*gateway)
  151. -         GetFullSiteName(gateway, NULL);
  152. - #endif
  153. -     /* If the hostname supplied was an abbreviation, such as just
  154. -      * "wu" (wuarchive.wustl.edu), look through the list of sites
  155. -      * we know about and get the whole name.  We also would like
  156. -      * the path we want to start out in, if it is available.
  157. -      */
  158. -     GetFullSiteName(openopt->hostname, openopt->cdpath);
  159.   
  160.       for (
  161.               dials = 0;
  162. --- 486,491 ----
  163. diff -c ./patchlevel.h ../ncftp152/patchlevel.h
  164. *** ./patchlevel.h    Sun Aug 29 22:14:06 1993
  165. --- ../ncftp152/patchlevel.h    Mon Aug 30 15:00:00 1993
  166. ***************
  167. *** 110,114 ****
  168. --- 110,119 ----
  169.    *  of .netrc.  TRY_ABOR documented in the README.  Added stuff to the
  170.    *  DYNIX entry.  Hacks added for SCO322.  Shortened bargraph prog meter
  171.    *  by one char.  Better compat with getline.  Man page fixed by DWS again :)
  172. +  *
  173. +  * v1.5.1 - August 30, 1993.
  174. +  *  Back to using "me" instead of "se" to for termcap_normal.  Fixed Netrc
  175. +  *  site abbrev problem in a different way (by getting the fullsite name
  176. +  *  before calling ruserpass2).
  177.    */
  178.   
  179. --
  180. --mg                                                      mgleason@cse.unl.edu
  181.  
  182. exit 0 # Just in case...
  183.