home *** CD-ROM | disk | FTP | other *** search
/ Amiga Elysian Archive / AmigaElysianArchive.iso / comm / amiga_nn.lha / amiga-nn / nn-6.4.16.diff < prev    next >
Text File  |  1993-03-29  |  88KB  |  3,443 lines

  1. diff -c +recursive +new-file nn-6.4.16/account.c ann/account.c
  2. *** nn-6.4.16/account.c    Fri Oct 12 22:44:00 1984
  3. --- ann/account.c    Thu Mar 27 17:52:31 1985
  4. ***************
  5. *** 40,45 ****
  6. --- 40,49 ----
  7.   #include "proto.h"
  8.   #include <errno.h>
  9.   
  10. + #ifdef    AMIGA
  11. + FILE    *debugfh;
  12. + #endif
  13.   import char *db_directory;
  14.   
  15.   
  16. ***************
  17. *** 382,387 ****
  18. --- 386,395 ----
  19.       char *fname;
  20.       int users, i;
  21.       struct account ac, *actab;
  22. + #ifdef    AMIGA
  23. +     debugfh=fopen("*","w");
  24. + #endif
  25.       
  26.       who_am_i = I_AM_ACCT;
  27.   
  28. diff -c +recursive +new-file nn-6.4.16/admin.c ann/admin.c
  29. *** nn-6.4.16/admin.c    Fri Oct 12 22:44:00 1984
  30. --- ann/admin.c    Thu Mar 27 17:54:15 1985
  31. ***************
  32. *** 11,16 ****
  33. --- 11,20 ----
  34.   #include "proto.h"
  35.   #include "term.h"
  36.   
  37. + #ifdef    AMIGA
  38. + extern    FILE    *debugfh;
  39. + #endif
  40.   import char
  41.       *master_directory, *db_directory, *db_data_directory,
  42.       *bin_directory, *news_directory, *news_lib_directory,
  43. ***************
  44. *** 168,178 ****
  45. --- 172,194 ----
  46.           return;
  47.       }
  48.       if (db_data_subdirs)
  49. + #ifdef    AMIGA
  50. +         sprintf(command, "cd %s ; list [0-9] | %s", db_data_directory, pager);
  51. + #else
  52.           sprintf(command, "cd %s ; ls -l [0-9] | %s", db_data_directory, pager);
  53. + #endif
  54.       else
  55. + #ifdef    AMIGA
  56. +     sprintf(command, "list %s | %s", db_data_directory, pager);
  57. + #else
  58.       sprintf(command, "ls -l %s | %s", db_data_directory, pager);
  59. + #endif
  60.       } else
  61. + #ifdef    AMIGA
  62. +     sprintf(command, "list %s", db_data_path(name, gh, '*'));
  63. + #else
  64.       sprintf(command, "ls -l %s", db_data_path(name, gh, '*'));
  65. + #endif
  66.       system(command);
  67.   }
  68.   
  69. ***************
  70. *** 310,315 ****
  71. --- 326,332 ----
  72.       goto err;
  73.       }
  74.   #endif
  75.   
  76.       ix = open_data_file(gh, 'x', OPEN_READ);
  77.       if (ix == NULL) valerr(("NO INDEX FILE"), 1);
  78. diff -c +recursive +new-file nn-6.4.16/amiga-aux.c ann/amiga-aux.c
  79. *** nn-6.4.16/amiga-aux.c
  80. --- ann/amiga-aux.c    Wed Mar 26 11:08:47 1985
  81. ***************
  82. *** 0 ****
  83. --- 1,208 ----
  84. + /*
  85. +     Aux script for the Amiga
  86. +     by Alexander Rawass, a_rawass@informatik.uni-kl.de
  87. + */
  88. + #include <stdio.h>
  89. + #include <exec/types.h>
  90. + #include "readconfig.h"
  91. + #define STREQU(x,y) (!(strcmp(x,y)))
  92. + #define STRNEQU(x,y,z) (!(strncmp(x,y,z)))
  93. + #define    INVOKED    argv[0]
  94. + #define    INVOKE_PATH    argv[1]
  95. + #define    COMMAND    argv[2]
  96. + #define    TEMPFILE    argv[3]
  97. + #define    ARTID    argv[4]
  98. + #define    GROUPNAME    argv[5]
  99. + #define    LAST_ARTICLE    "t:last.article"
  100. + #define    LMAX 200
  101. + int    main(argc,argv)
  102. + int    argc;
  103. + STRPTR    argv[];
  104. + {
  105. +     char    combuf[100];
  106. +     char    ans[10];
  107. +     char    ans2[10];
  108. +     int        st;
  109. +     char    buf[LMAX];
  110. +     FILE    *tfh;
  111. +     FILE    *sfh;
  112. +     int        i;
  113. +     FILE    *fh;
  114. +     struct    uuconfig    conf;
  115. +     if(!STREQU(INVOKED,"amiga-aux")){
  116. +         printf("not invoked as nnaux, invoked as %s\n",INVOKED);
  117. +         exit(1);
  118. +     }
  119. +     
  120. +     if(readconfig("uulib:config",&conf)==FALSE
  121. +         || readconfig("uulib:.nnrc",&conf)==FALSE){
  122. +         printf("ERROR: uulib:config and/or uulib:.nnrc not found\n");
  123. +         sleep(3);
  124. +         exit(9);        
  125. +     }
  126. +     if(STREQU(COMMAND,"post") || STREQU(COMMAND,"follow")){
  127. +         sprintf(combuf,"%s %s",conf.Editor,TEMPFILE);
  128. +         system(combuf);
  129. +         
  130. +         do{
  131. + /*            printf("\na)bort e)dit h)old m)ail r)eedit s)end v)iew w)rite\n");    */
  132. +             printf("\na)bort e)dit m)ail s)end v)iew p)ost\n");
  133. +             printf("Action: (post article) ");    fflush(stdout);
  134. +             scanf("%s",&ans);
  135. +             
  136. +             switch(ans[0]){
  137. +                 case 'a':
  138. +                 printf("\nConfirm abort: (y) ");    fflush(stdout);
  139. +                 scanf("%s",&ans2);
  140. +                 if(ans2[0]=='y'){
  141. +                     unlink(LAST_ARTICLE);
  142. +                     rename(TEMPFILE,LAST_ARTICLE);
  143. +                     exit(22);
  144. +                 }
  145. +                 break;
  146. +                 case 'e':
  147. +                 sprintf(combuf,"%s %s",conf.Editor,TEMPFILE);
  148. +                 system(combuf);
  149. +                 break;
  150. +                 case 'm':
  151. +                 /* mailer */
  152. +                 break;
  153. +                 case 'v':
  154. +                 sprintf(combuf,"more %s",TEMPFILE);
  155. +                 system(combuf);
  156. +                 break;
  157. +                 /*            case '\n':    */
  158. +                 case 'p':
  159. +                 case 's':
  160. +                 sprintf(combuf,"%s %s",conf.NewsCommand,TEMPFILE);
  161. +                 st=system(combuf);
  162. +                 if(st==0){
  163. +                     printf("Be patient! Your new article will not show up immediately.\n");
  164. +                 }
  165. +                 else{
  166. +                     printf("Posting not sent!\n");
  167. +                 }
  168. +                 sleep(2);
  169. +                 unlink(LAST_ARTICLE);
  170. +                 rename(TEMPFILE,LAST_ARTICLE);
  171. +                 exit(st);
  172. +                 break;
  173. +                 default:
  174. +                 printf("command %c) not yet supported\n",ans[0]);
  175. +                 break;
  176. +             }
  177. +         }
  178. +         while(TRUE);
  179. +     }
  180. +     else if(STREQU(COMMAND,"mail") || STREQU(COMMAND,"forward")
  181. +     || STREQU(COMMAND,"reply")){
  182. +         sprintf(combuf,"%s %s",conf.Editor,TEMPFILE);
  183. +         system(combuf);
  184. +         
  185. +         do{
  186. + /*            printf("\na)bort e)dit h)old m)ail r)eedit s)end v)iew w)rite\n");    */
  187. +             printf("\na)bort e)dit m)ail s)end v)iew\n");
  188. +             printf("Action: (send letter) ");    fflush(stdout);
  189. +             scanf("%s",&ans);
  190. +             
  191. +             switch(ans[0]){
  192. +                 case 'a':
  193. +                 printf("\nConfirm abort: (y) ");    fflush(stdout);
  194. +                 scanf("%s",&ans2);
  195. +                 if(ans2[0]=='y'){
  196. +                     unlink(LAST_ARTICLE);
  197. +                     rename(TEMPFILE,LAST_ARTICLE);
  198. +                     exit(22);
  199. +                 }
  200. +                 break;
  201. +                 case 'e':
  202. +                 sprintf(combuf,"%s %s",conf.Editor,TEMPFILE);
  203. +                 system(combuf);
  204. +                 break;
  205. +                 case 'm':
  206. +                 /* mailer */
  207. +                 break;
  208. +                 case 'v':
  209. +                 sprintf(combuf,"more %s",TEMPFILE);
  210. +                 system(combuf);
  211. +                 break;
  212. +                 case 's':
  213. +                 /* sendmail haengt keine signature an */
  214. +                 /* also tuen wir das */
  215. +                 
  216. +                 tfh=fopen(TEMPFILE,"a+");
  217. +                 sfh=fopen(conf.MailSignature,"r");
  218. +                 fgets(buf,LMAX,sfh);
  219. +                 while(!feof(sfh)){
  220. +                     fputs(buf,tfh);
  221. +                     fgets(buf,LMAX,sfh);
  222. +                 }
  223. +                 fclose(sfh);
  224. +                 
  225. +                 fclose(tfh);
  226. +                 sprintf(combuf,"%s %s",conf.MailCommand,TEMPFILE);
  227. +                 st=system(combuf);
  228. +                 if(st==0){
  229. +                     printf("Mail sent!\n");
  230. +                 }
  231. +                 else{
  232. +                     printf("Mailer failed!\n");
  233. +                 }
  234. +                 sleep(2);
  235. +                 unlink(LAST_ARTICLE);
  236. +                 rename(TEMPFILE,LAST_ARTICLE);
  237. +                 exit(st);
  238. +                 break;
  239. +                 default:
  240. +                 printf("command %c) not yet supported\n",ans[0]);
  241. +                 break;
  242. +             }
  243. +         }
  244. +         while(TRUE);
  245. +     }
  246. +     else if(STREQU(COMMAND,"cancel")){
  247. +         fh=fopen(TEMPFILE,"w");
  248. +         if(fh==NULL){
  249. +             printf("cannot open %s\n",TEMPFILE);
  250. +             exit(78);
  251. +         }
  252. +         fprintf(fh,"Newsgroups: %s\n",GROUPNAME);
  253. +         fprintf(fh,"Subject: cancel <%s>\n",ARTID);
  254. +         fprintf(fh,"Control: cancel <%s>\n",ARTID);
  255. +         fprintf(fh,"\n");
  256. +         fprintf(fh,"cancel <%s> in newsgroup %s\n",ARTID,GROUPNAME);
  257. +         fclose(fh);
  258. +                 sprintf(combuf,"%s %s",conf.NewsCommand,TEMPFILE);
  259. +                 st=system(combuf);
  260. +                 if(st==0){
  261. +                     printf("Article cancelled!\n");
  262. +                 }
  263. +                 else{
  264. +                     printf("Article not cancelled!\n");
  265. +                 }
  266. +                 sleep(2);
  267. +                 unlink(LAST_ARTICLE);
  268. +                 rename(TEMPFILE,LAST_ARTICLE);
  269. +                 exit(st);
  270. +     }
  271. +     else{
  272. +         printf("command %s not understood\n",COMMAND);
  273. +         for(i=0;i<argc;i++){
  274. +             printf("%s\n",argv[i]);
  275. +         }
  276. +         sleep(10);
  277. +         exit(1);
  278. +     }
  279. + }
  280. diff -c +recursive +new-file nn-6.4.16/answer.c ann/answer.c
  281. *** nn-6.4.16/answer.c    Fri Oct 12 22:44:00 1984
  282. --- ann/answer.c    Thu Mar 27 17:55:22 1985
  283. ***************
  284. *** 11,16 ****
  285. --- 11,25 ----
  286.   #include "options.h"
  287.   #include "regexp.h"
  288.   
  289. + #ifdef AMIGA
  290. + #define    FALSE    0L
  291. + #include "readconfig.h"
  292. + #endif
  293. + #ifdef    AMIGA
  294. + extern    FILE    *debugfh;
  295. + #endif
  296.   extern char *temp_file;
  297.   extern char *news_lib_directory;
  298.   
  299. ***************
  300. *** 336,341 ****
  301. --- 345,351 ----
  302.       extern char *nntp_get_filename();
  303.   #endif
  304.   
  305.       if (strcmp(prog, "COMPLETE") == 0) goto no_params;
  306.   
  307.       param = open_file(relative(nn_directory, ".param"), OPEN_CREATE);
  308. ***************
  309. *** 411,420 ****
  310. --- 421,449 ----
  311.       *ap++ = temp_file;
  312.       *ap++ = NULL;
  313.   
  314. + #ifdef AMIGA
  315. + {
  316. + char    myid[200];
  317. + if(strcmp(prog,"cancel")==0){
  318. +     ap--;
  319. +     strncpy(myid,action+1,strlen(action)-2);
  320. +     *ap++ = myid;        /* id */
  321. +     *ap++ = record;        /* group */
  322. +     *ap++ = NULL;
  323. + }
  324. +     if (execute("amiga-aux", args, 1)) {
  325. +     sprintf(delayed_msg, sent_fmt, " not");
  326. +     return 1;
  327. +     }
  328. + }
  329. + #else
  330.       if (execute(SHELL, args, 1)) {
  331.       sprintf(delayed_msg, sent_fmt, " not");
  332.       return 1;
  333.       }
  334. + #endif
  335.       sprintf(delayed_msg, sent_fmt, "");
  336.       return 0;
  337.   }
  338. ***************
  339. *** 769,775 ****
  340. --- 798,817 ----
  341.       char hname[100], *un;
  342.   
  343.       if (inetname == NULL) {
  344. + #ifdef AMIGA
  345. + {
  346. + struct    uuconfig    conf;
  347. +     if(readconfig("uulib:config",&conf)==FALSE){
  348. +         gethostname(hname,100);    /* returns 'amiga' */
  349. +     }
  350. +     else{
  351. +         sprintf(hname,"%s%s",&(conf.NodeName),&(conf.DomainName));
  352. +     }
  353. + }
  354. + #else
  355.       gethostname(hname, 100);
  356. + #endif
  357.       un = user_name();
  358.       inetname = newstr(strlen(hname) + strlen(un) + 2);
  359.       sprintf(inetname, "%s@%s", un, hname);
  360. diff -c +recursive +new-file nn-6.4.16/collect.c ann/collect.c
  361. *** nn-6.4.16/collect.c    Fri Oct 12 22:44:00 1984
  362. --- ann/collect.c    Thu Mar 27 17:56:20 1985
  363. ***************
  364. *** 8,13 ****
  365. --- 8,17 ----
  366.   #include "db.h"
  367.   #include "news.h"
  368.   
  369. + #ifdef    AMIGA
  370. + extern FILE    *debugfh;
  371. + #endif
  372.   #define COUNT_RE_REFERENCES    /* no of >>> depends on Reference: line */
  373.   
  374.   export int ignore_bad_articles = 1;    /* no Newsgroups: line */
  375. ***************
  376. *** 318,323 ****
  377. --- 322,328 ----
  378.       long article_count, temp, obad;
  379.       article_number start_collect;
  380.   
  381.       if (gh->last_db_article == 0) {
  382.       gh->first_db_article = gh->first_a_article;
  383.       gh->last_db_article = gh->first_db_article - 1;
  384. ***************
  385. *** 415,420 ****
  386. --- 420,426 ----
  387.       int col_group_count;
  388.       time_t start_time;
  389.   
  390.       start_time = cur_time();
  391.       col_article_count = col_group_count = 0;
  392.       current_group = NULL; /* for init_group */
  393. ***************
  394. *** 426,433 ****
  395. --- 432,441 ----
  396.           break;
  397.       }
  398.   
  399.       if (gh->master_flag & M_IGNORE_GROUP) continue;
  400.   
  401.       if (gh->master_flag & M_MUST_CLEAN)
  402.           clean_group(gh);
  403.   
  404. ***************
  405. *** 436,441 ****
  406. --- 444,450 ----
  407.           continue;
  408.       }
  409.   
  410.       if (!init_group(gh)) {
  411.           if ((gh->master_flag & M_NO_DIRECTORY) == 0) {
  412.           log_entry('R', "%s: no directory", gh->group_name);
  413. ***************
  414. *** 448,458 ****
  415. --- 457,469 ----
  416.           continue;
  417.       }
  418.   
  419.       if (gh->master_flag & M_NO_DIRECTORY) {
  420.           /* The directory has been created now */
  421.           gh->master_flag &= ~M_NO_DIRECTORY;
  422.           clean_group(gh);
  423.       }
  424.   
  425.       temp = collect_group(gh);
  426.   #ifdef NNTP
  427. diff -c +recursive +new-file nn-6.4.16/conf/s-amiga.h ann/conf/s-amiga.h
  428. *** nn-6.4.16/conf/s-amiga.h
  429. --- ann/conf/s-amiga.h    Fri Mar 28 10:04:39 1985
  430. ***************
  431. *** 0 ****
  432. --- 1,143 ----
  433. + /* system file for AMIGA */
  434. + #define    AMIGA
  435. + /*
  436. +  *    System V based system
  437. +  *    TERMCAP is used instead of TERMINFO
  438. +  */
  439. + /*
  440. +  *    This is a generic System V Release 2 & 3 file.
  441. +  *
  442. +  *    If you need to modify anything, make a new s- file,
  443. +  *    #include this file, and #define or #undef a few symbols.
  444. +  */
  445. + /*
  446. +  *    Include header files containing the following definitions:
  447. +  *
  448. +  *         off_t, time_t, struct stat
  449. +  */
  450. + #ifdef lint
  451. + struct proc {    /* sys/types.h references this on many systems */
  452. +     int keep_lint_happy;
  453. + };
  454. + #endif
  455. + #include <sys/types.h>
  456. + #include <sys/stat.h>
  457. + /*
  458. +  *    Define if your system has system V like ioctls
  459. +  */
  460. + /* #define    HAVE_TERMIO */            /* */
  461. + /*
  462. +  *    Define to use terminfo database.
  463. +  *    Otherwise, termcap is used
  464. +  */
  465. + #define    USE_TERMINFO            /* */
  466. + /*
  467. +  *    Specify the library containing the termcap/terminfo access routines.
  468. +  *    Notice:  nn does not use curses.
  469. +  *    Notice:  You must also specify whether termcap or terminfo is
  470. +  *         used when you edit config.h (see below).
  471. +  */
  472. + #define    TERMLIB -lcurses
  473. + /*
  474. +  *    Define HAVE_STRCHR if strchr() and strrchr() are available
  475. +  */
  476. + #define HAVE_STRCHR            /* */
  477. + /*
  478. +  *    Define if a signal handler has type void (see signal.h)
  479. +  */
  480. + #define    SIGNAL_HANDLERS_ARE_VOID    /* */
  481. + /*
  482. +  *    Define if signals must be set again after they are caught
  483. +  */
  484. + #define    RESET_SIGNAL_WHEN_CAUGHT    /* */
  485. + /*
  486. +  *    Define if your system has BSD like job control (SIGTSTP works)
  487. +  */
  488. + /* #define HAVE_JOBCONTROL            /* */
  489. + /*
  490. +  *    Define if your system provides the "directory(3X)" access routines
  491. +  *
  492. +  *    If true, include the header file(s) required by the package below
  493. +  *    (remember that <sys/types.h> or equivalent is included above)
  494. +  *    Also typedef Direntry to the proper struct type.
  495. +  */
  496. + #ifdef NO_DIRENT_H
  497. + #undef NO_DIRENT_H
  498. + #else
  499. + #define    HAVE_DIRECTORY            /* */
  500. + #include <dirent.h>            /* System V */
  501. + typedef struct dirent Direntry;        /* System V */
  502. + #endif
  503. + /*
  504. +  *    Define if your system has a mkdir() library routine
  505. +  */
  506. + #define    HAVE_MKDIR            /* */
  507. + /*
  508. +  *    Define HAVE_GETHOSTNAME if your system provides a BSD like
  509. +  *    gethostname routine.
  510. +  *    Otherwise, define HAVE_UNAME if uname() is avaiable.
  511. +  *    As a final resort, define HOSTNAME to the name of your system.
  512. +  */
  513. + #define    HAVE_GETHOSTNAME            /* System V */
  514. + /*
  515. +  *    Define DETATCH_TERMINAL to be a command sequence which
  516. +  *    will detatch a process from the control terminal
  517. +  *    Also include files needed to perform this HERE.
  518. +  *    If not possible, just define it (empty)
  519. +  */
  520. + #define    DETATCH_TERMINAL setpgrp();    /* System V */
  521. + /*
  522. +  *    Specify where the Bourne Shell is.
  523. +  */
  524. + #define SHELL        "/bin/sh"
  525. + /*
  526. +  *    Specify the default mailer to be invoked by nnmail
  527. +  */
  528. + #define    MAILX        "/usr/bin/rmail"    /* SV */
  529. + /*
  530. +  *    Define the maximum length of any pathname that may occur
  531. +  */
  532. + #define    FILENAME     256
  533. + #undef USE_TERMINFO
  534. + #undef TERMLIB
  535. + #define TERMLIB -ltermlib
  536. diff -c +recursive +new-file nn-6.4.16/config.h ann/config.h
  537. *** nn-6.4.16/config.h    Wed Feb 06 06:27:00 1985
  538. --- ann/config.h
  539. ***************
  540. *** 1,381 ****
  541. - /**************************** NN CONFIGURATION ***************************
  542. -  *
  543. -  *    Configuration file for nn.
  544. -  *
  545. -  *    You must edit this file to reflect your local configuration
  546. -  *    and environment.
  547. -  *
  548. -  *    Before editing this file, read the licence terms in the README
  549. -  *    file and the installation guidelines in the INSTALLATION file.
  550. -  *
  551. -  *    (c) Copyright 1990, Kim F. Storm.  All rights reserved.
  552. -  */
  553. - #define    RELEASE     "6.4"
  554. - #include <stdio.h>
  555. - #include <ctype.h>
  556. - /*********************** NETWORK DEPENDENT DEFINITIONS **********************
  557. -  *
  558. - Y *    Define NETWORK_DATABASE if you share the database through NFS on
  559. -  *    a network with different, non-compatible machines, e.g. SUNs and
  560. -  *    VAXen, or SUN-3 and SUN-4, or if you are using different compilers
  561. -  *    on the same architecture.
  562. -  *
  563. -  *    In a homogenous network, you can leave it undefined for higher
  564. -  *    performance (no data conversion is needed).
  565. -  */
  566. - /* #define NETWORK_DATABASE    /* */
  567. - /********************************** NNTP *********************************
  568. -  *
  569. -  *     Define NNTP to enable nntp support.  If you are not using NNTP,
  570. -  *    just leave the following NNTP_* definitions as they are - they
  571. -  *    will be ignored anyway.
  572. -  *
  573. -  *    With NNTP, the nnmaster still maintains a local database of
  574. -  *    all article headers for fast access (and because NNTP does not
  575. -  *    support nn - yet), while the articles are fetched from the
  576. -  *    nntp server when they are read or saved.
  577. -  *
  578. -  *    You may still share this database through NFS locally (see the
  579. -  *    description of NETWORK_DATABASE above) if you don't want to
  580. -  *    have separate nn databases on all your local systems.
  581. -  *
  582. -  *    Consult the file NNTP for further information on the use of NNTP.
  583. -  */
  584. - /* #define NNTP            /* */
  585. - /*
  586. -  *    Define NNTP_SERVER to the name of a file containing the name of the
  587. -  *    nntp server.
  588. -  *
  589. -  *    It is vital that both the nnmaster and all nn users on a machine
  590. -  *    uses the same nntp server, because the nn database is synchronized
  591. -  *    with a specific news active file.
  592. -  *
  593. -  *    If the file name does not start with a slash, it is relative to
  594. -  *    LIB_DIRECTORY defined below.
  595. -  *    NOTE: If you plan to use the included inews, it MUST be a full pathname
  596. -  */
  597. - /* #define NNTP_SERVER    "/usr/local/lib/news/nntp/nntp_server"
  598. - /*
  599. -  *    Define NNTP_POST if you want nn to reject attempts to post via
  600. -  *    NNTP to a server, that disallows postings.
  601. -  *
  602. -  *    You should define this, if you use the NNTP based mini-inews for
  603. -  *    postings from NNTP clients.  If you use another mechanism, that
  604. -  *    does not involve NNTP, you should leave it undefined.
  605. -  */
  606. - /* #define NNTP_POST             /* */
  607. - /*
  608. -  *    NNTP's mini-inews seems to require that messages contain a complete
  609. -  *    header with Message-ID, Path, and Date fields which the normal inews
  610. -  *    generates itself.  If your mini-inews requires these headers to
  611. -  *    be present, define NNTP_MINI_INEWS_HEADER below.
  612. -  */
  613. - /* #define NNTP_MINI_INEWS_HEADER    /* uses "broken" mini-inews */
  614. - /***************** OPERATING SYSTEM DEPENDENT DEFINITIONS *******************
  615. -  *
  616. -  *      Include the appropriate s- file for your system below.
  617. -  *
  618. -  *    If a file does not exist for your system, you can use
  619. -  *    conf/s-template.h as a starting point for writing you own.
  620. -  */
  621. - #include "s-sys5-tcap.h"                /* 4.2 BSD and Ultrix */
  622. - /*
  623. -  *    Define DEFAULT_PAGER as the initial value of the 'pager' variable.
  624. -  *    nnadmin pipes shell command output though this command.
  625. -  */
  626. - #define DEFAULT_PAGER    "less"    /* system V */
  627. - /* #define DEFAULT_PAGER        "more"        /* bsd */
  628. - /*
  629. -  *    DEFAULT_PRINTER is the initial value of the 'printer' variable.
  630. -  *    nn's :print command pipes text into this command.
  631. -  */
  632. - /* #define DEFAULT_PRINTER    "lp -s"        /* System V */
  633. - #define DEFAULT_PRINTER        "lpr -h"    /* bsd */
  634. - /*
  635. -  *     Define RESIZING to make nn understand dynamic window-resizing.
  636. -  *     (It uses the TIOCGWINSZ ioctl found on most 4.3BSD systems)
  637. -  */
  638. - #define RESIZING        /* */
  639. - /********************** MACHINE DEPENDENT DEFINITIONS **********************
  640. -  *
  641. -  *    Include the appropriate m- file for your system below.
  642. -  *
  643. -  *    If a file does not exist for your system, you can use
  644. -  *    conf/m-template.h as a starting point for writing you own.
  645. -  */
  646. - #include "m-i80386.h"
  647. - /***************************** OWNERSHIP ***************************
  648. -  *
  649. -  *    Specify owner and group for installed files and programs.
  650. -  *
  651. -  *    The nnmaster will run suid/sgid to this owner and group.
  652. -  *
  653. -  *    The only requirements are that the ownership allows the
  654. -  *    nnmaster to READ the news related files and directories, and
  655. -  *    the ordinary users to read the database and execute the nn*
  656. -  *    programs.
  657. -  *
  658. -  *    Common choices are:  (news, news)  and   (your uid, your gid)
  659. -  */
  660. - #define OWNER    "news"
  661. - #define    GROUP    "news"
  662. - /**************************** LOCALIZATION ****************************
  663. -  *
  664. -  *    Specify where programs and files are installed.
  665. -  *
  666. -  *    BIN_DIRECTORY    - the location of the user programs (mandatory)
  667. -  *
  668. -  *    LIB_DIRECTORY     - the location of auxiliary programs and files.
  669. -  *               (mandatory UNLESS ALL of the following are defined).
  670. -  *
  671. -  *    MASTER_DIRECTORY - the location of the master program (on server)
  672. -  *               (= LIB_DIRECTORY if undefined)
  673. -  *
  674. -  *    CLIENT_DIRECTORY - the location of auxiliary programs (on clients)
  675. -  *               (= LIB_DIRECTORY if undefined)
  676. -  *
  677. -  *    HELP_DIRECTORY   - the location of help files, online manual, etc.
  678. -  *               (= CLIENT_DIRECTORY/help if undefined)
  679. -  *
  680. -  *    CACHE_DIRECTORY     - if NNTP is used, nn uses this central directory
  681. -  *               to store working copies of articles on the local
  682. -  *               system.  If not defined, it stores the articles
  683. -  *               in each user's ~/.nn directory.
  684. -  *
  685. -  *    TMP_DIRECTORY    - temporary file storage.  Overriden by $TMPDIR.
  686. -  *               (= /usr/tmp if undefined).
  687. -  *
  688. -  *    LOG_FILE         - the location of nn's log file.
  689. -  *               (= LIB_DIRECTORY/Log if undefined).
  690. -  */
  691. - #define BIN_DIRECTORY    "/usr/local/bin"
  692. - #define LIB_DIRECTORY    "/usr/local/lib/nn"
  693. - /**************************** DATABASE LOCATION **************************
  694. -  *
  695. -  *    Specify where the nn database should be installed.
  696. -  *
  697. -  *    If none of the following symbols are defined, the database will
  698. -  *    be contained in the NEWS_DIRECTORY in a separate .nn directory for
  699. -  *    master files and in files named .nnx and .nnd in each group's
  700. -  *    spool directory.  To use this scheme, the OWNER specified above
  701. -  *    must have write permission on the news spool directories.
  702. -  *
  703. -  *    If you access news via NNTP, you will probably always have to
  704. -  *    give the database directory explicitly through DB_DIRECTORY
  705. -  *    (and DB_DATA_DIRECTORY), since the normal news spool directories 
  706. -  *    are probably not available on the local system.
  707. -  *    The exception may be if nnmaster runs directly on the nntp server.
  708. -  -
  709. -  *
  710. -  *    To change the default behaviour, you can define the following
  711. -  *    symbols:
  712. -  *
  713. -  *    DB_DIRECTORY       - the directory containing the master files.
  714. -  *
  715. -  *    DB_DATA_DIRECTORY  - the directory containing the per-group files
  716. -  *                 (default is DB_DIRECTORY/DATA if undefined).
  717. -  *
  718. -  *    DB_LONG_NAMES       - use group's name rather than number when
  719. -  *                 building file names in DB_DATA_DIRECTORY.
  720. -  *         (The file system must support long file names!!)
  721. -  */
  722. - /* #define DB_DIRECTORY    "/usr/spool/nn-6.4" */
  723. - #define DB_DIRECTORY    "/usr/spool/news/.nn"
  724. - /*************************** NEWS TRANSPORT **************************
  725. -  *
  726. -  *    Specify the location of your news programs and files
  727. -  *    You only need to specify these if you are not
  728. -  *    satisfied with the default settings.
  729. -  *
  730. -  *    NEWS_DIRECTORY         - The news spool directory.
  731. -  *                  Default: /usr/spool/news
  732. -  *
  733. -  *    NEWS_LIB_DIRECTORY    - The news lib directory.
  734. -  *                  Default: /usr/lib/news
  735. -  *
  736. -  *    INEWS_PATH        - The location of the inews program.
  737. -  *                  Default: NEWS_LIB_DIR/inews
  738. -  *
  739. -  *    RMGROUP_PATH        - The location of the rmgroup program.
  740. -  *                  Default: NEWS_LIB_DIR/{rm,del}group
  741. -  */
  742. - #define NEWS_DIRECTORY        "/usr/spool/news"    /* */
  743. - #define NEWS_LIB_DIRECTORY    "/usr/lib/news"    /* */
  744. - /* #define INEWS_PATH        "/usr/lib/news/inews"    /* */
  745. - /*************************** MAIL INTERFACE *************************
  746. -  *
  747. -  *    Specify a mailer that accepts a letter WITH a header IN THE TEXT.
  748. -  *
  749. -  *     A program named 'recmail' program is normally delivered with
  750. -  *    the Bnews system, or you can use sendmail -t if you have it.
  751. -  *
  752. -  *    The contrib/ directory contains two programs which you might
  753. -  *    be able to use with a little tweaking.
  754. -  */
  755. - /* #define REC_MAIL    "/usr/lib/news/recmail"    /* non-sendmail */
  756. - #define REC_MAIL    "/usr/bin/smail"    /* sendmail */
  757. - /*
  758. -  *    Define HAVE_ROUTING if your mailer understands domain based
  759. -  *    adresses (...@...) and performs the necessary rerouting (e.g.
  760. -  *    Sendmail or Smail).
  761. -  *
  762. -  *    Otherwise, nn will provide a simple routing facility using
  763. -  *      routing information specified in the file LIB_DIRECTORY/routes.
  764. -  */
  765. - #define HAVE_ROUTING            /* */
  766. - /*
  767. -  *    If HAVE_ROUTING is NOT defined, nn needs to know the name of
  768. -  *     your host.  To obtain the host name it will use either of the
  769. -  *    'uname' or 'gethostname' system calls as specified in the s-
  770. -  *    file included above.
  771. -  *
  772. -  *    If neither 'uname' nor 'gethostname' is available, you must
  773. -  *    define HOSTNAME to be the name of your host.  Otherwise, leave
  774. -  *    it undefined (it will not be used anyway).
  775. -  */
  776. - /* #define HOSTNAME    "myhost"    /* Not used if HAVE_ROUTING */
  777. - /*
  778. -  *    Define APPEND_SIGNATURE if you want nn to ask users to append
  779. -  *    ~/.signature to mail messages (reply/forward/mail).
  780. -  *
  781. -  *    If the mailer defined in REC_MAIL automatically includes .signature
  782. -  *    you should not define this (it will fool people to include it twice).
  783. -  *
  784. -  *    I think 'recmail' includes .signature, but 'sendmail -t' doesn't.
  785. -  */
  786. - #define APPEND_SIGNATURE        /* */
  787. - /*
  788. -  *    BUG_REPORT_ADDRESS is the initial value of the bug-report-address
  789. -  *    variable which is used by the :bug command to report bugs in
  790. -  *    the nn software.
  791. -  */
  792. - #define BUG_REPORT_ADDRESS    "news"
  793. - /*************************** DOCUMENTATION ***************************
  794. -  *
  795. -  *     Specify directories for the user and system manuals
  796. -  *
  797. -  *     Adapt this to your local standards; the manuals will be named
  798. -  *         $(MAN_DIR)/program.$(MAN_SECTION)
  799. -  *
  800. -  *    USER_MAN    - nn, nntidy, nngrep, etc.
  801. -  *    SYS_MAN        - nnadmin
  802. -  *    DAEMON_MAN    - nnmaster
  803. -  */
  804. - #define USER_MAN_DIR     "/usr/local/man/man1"
  805. - #define USER_MAN_SECTION     "1"
  806. - #define SYS_MAN_DIR     "/usr/local/man/man1"
  807. - #define SYS_MAN_SECTION     "1m"
  808. - #define DAEMON_MAN_DIR     "/usr/local/man/man8"
  809. - #define DAEMON_MAN_SECTION     "8"
  810. - /************************** LOCAL POLICY *****************************
  811. -  *
  812. -  *    Define STATISTICS if you want to keep a record of how much
  813. -  *    time the users spend on news reading.
  814. -  *
  815. -  *    Sessions shorter than the specified number of minutes are not
  816. -  *    recorded (don't clutter up the log file).
  817. -  *
  818. -  *    Usage statistics is entered into the $LOG_FILE with code U
  819. -  */
  820. - /* #define STATISTICS    5 /* minutes */
  821. - /*
  822. -  *    Define ACCOUNTING if you want to keep accumulated accounting
  823. -  *    based on the statistics in a separate 'acct' file.  In this
  824. -  *    case, the accounting figures will be secret, and not be
  825. -  *    written to the Log file.  And the users will not be able to
  826. -  *    "decrease" their own account.
  827. -  *
  828. -  *    See account.c for optional cost calculation parameters.
  829. -  */
  830. - /* #define ACCOUNTING        /* */
  831. - /*
  832. -  *    Define AUTHORIZE if you want to restrict the use of nn to
  833. -  *    certain users or certain periods of the day.  Define both
  834. -  *    this and ACCOUNTING if you want to impose a usage quota
  835. -  *
  836. -  *    See account.c for implementing various access policies.
  837. -  */
  838. - /* #define AUTHORIZE    /* */
  839. - /*
  840. -  *    Default folder directory
  841. -  */
  842. - #define FOLDER_DIRECTORY    "~/News"
  843. - /*
  844. -  *    Max length of authors name (in "edited" format).
  845. -  *    Also size of "Name" field on the article menus.
  846. -  *    You may want to increase this if your terminals are wider than
  847. -  *    80 columns.
  848. -  */
  849. - #define NAME_LENGTH         16
  850. - /************************ CONFIGURATION COMPLETED ************************/
  851. - #include "global.h"
  852. --- 0 ----
  853. diff -c +recursive +new-file nn-6.4.16/config.h-amiga ann/config.h-amiga
  854. *** nn-6.4.16/config.h-amiga
  855. --- ann/config.h-amiga    Fri Mar 28 10:03:08 1985
  856. ***************
  857. *** 0 ****
  858. --- 1,386 ----
  859. + /**************************** NN CONFIGURATION ***************************
  860. +  *
  861. +  *    Configuration file for nn.
  862. +  *
  863. +  *    You must edit this file to reflect your local configuration
  864. +  *    and environment.
  865. +  *
  866. +  *    Before editing this file, read the licence terms in the README
  867. +  *    file and the installation guidelines in the INSTALLATION file.
  868. +  *
  869. +  *    (c) Copyright 1990, Kim F. Storm.  All rights reserved.
  870. +  */
  871. + /*
  872. +     modified to work with the Amiga by Alexander Rawass
  873. + */
  874. + #define    RELEASE     "6.4"
  875. + #include <stdio.h>
  876. + #include <ctype.h>
  877. + /*********************** NETWORK DEPENDENT DEFINITIONS **********************
  878. +  *
  879. + Y *    Define NETWORK_DATABASE if you share the database through NFS on
  880. +  *    a network with different, non-compatible machines, e.g. SUNs and
  881. +  *    VAXen, or SUN-3 and SUN-4, or if you are using different compilers
  882. +  *    on the same architecture.
  883. +  *
  884. +  *    In a homogenous network, you can leave it undefined for higher
  885. +  *    performance (no data conversion is needed).
  886. +  */
  887. + /* #define NETWORK_DATABASE    /* */
  888. + /********************************** NNTP *********************************
  889. +  *
  890. +  *     Define NNTP to enable nntp support.  If you are not using NNTP,
  891. +  *    just leave the following NNTP_* definitions as they are - they
  892. +  *    will be ignored anyway.
  893. +  *
  894. +  *    With NNTP, the nnmaster still maintains a local database of
  895. +  *    all article headers for fast access (and because NNTP does not
  896. +  *    support nn - yet), while the articles are fetched from the
  897. +  *    nntp server when they are read or saved.
  898. +  *
  899. +  *    You may still share this database through NFS locally (see the
  900. +  *    description of NETWORK_DATABASE above) if you don't want to
  901. +  *    have separate nn databases on all your local systems.
  902. +  *
  903. +  *    Consult the file NNTP for further information on the use of NNTP.
  904. +  */
  905. + /* #define NNTP            /* */
  906. + /*
  907. +  *    Define NNTP_SERVER to the name of a file containing the name of the
  908. +  *    nntp server.
  909. +  *
  910. +  *    It is vital that both the nnmaster and all nn users on a machine
  911. +  *    uses the same nntp server, because the nn database is synchronized
  912. +  *    with a specific news active file.
  913. +  *
  914. +  *    If the file name does not start with a slash, it is relative to
  915. +  *    LIB_DIRECTORY defined below.
  916. +  *    NOTE: If you plan to use the included inews, it MUST be a full pathname
  917. +  */
  918. + /* #define NNTP_SERVER    "/usr/local/lib/news/nntp/nntp_server"
  919. + /*
  920. +  *    Define NNTP_POST if you want nn to reject attempts to post via
  921. +  *    NNTP to a server, that disallows postings.
  922. +  *
  923. +  *    You should define this, if you use the NNTP based mini-inews for
  924. +  *    postings from NNTP clients.  If you use another mechanism, that
  925. +  *    does not involve NNTP, you should leave it undefined.
  926. +  */
  927. + /* #define NNTP_POST             /* */
  928. + /*
  929. +  *    NNTP's mini-inews seems to require that messages contain a complete
  930. +  *    header with Message-ID, Path, and Date fields which the normal inews
  931. +  *    generates itself.  If your mini-inews requires these headers to
  932. +  *    be present, define NNTP_MINI_INEWS_HEADER below.
  933. +  */
  934. + /* #define NNTP_MINI_INEWS_HEADER    /* uses "broken" mini-inews */
  935. + /***************** OPERATING SYSTEM DEPENDENT DEFINITIONS *******************
  936. +  *
  937. +  *      Include the appropriate s- file for your system below.
  938. +  *
  939. +  *    If a file does not exist for your system, you can use
  940. +  *    conf/s-template.h as a starting point for writing you own.
  941. +  */
  942. + #include "s-amiga.h"                /* AMIGA */
  943. + /*
  944. +  *    Define DEFAULT_PAGER as the initial value of the 'pager' variable.
  945. +  *    nnadmin pipes shell command output though this command.
  946. +  */
  947. + /* #define DEFAULT_PAGER    "less"    */ /* system V */
  948. + #define DEFAULT_PAGER        "more"        /* bsd */
  949. + /*
  950. +  *    DEFAULT_PRINTER is the initial value of the 'printer' variable.
  951. +  *    nn's :print command pipes text into this command.
  952. +  */
  953. + /* #define DEFAULT_PRINTER    "lp -s"        /* System V */
  954. + #define DEFAULT_PRINTER        "type >prt:"    /* bsd */
  955. + /*
  956. +  *     Define RESIZING to make nn understand dynamic window-resizing.
  957. +  *     (It uses the TIOCGWINSZ ioctl found on most 4.3BSD systems)
  958. +  */
  959. + #define RESIZING        /* */
  960. + /********************** MACHINE DEPENDENT DEFINITIONS **********************
  961. +  *
  962. +  *    Include the appropriate m- file for your system below.
  963. +  *
  964. +  *    If a file does not exist for your system, you can use
  965. +  *    conf/m-template.h as a starting point for writing you own.
  966. +  */
  967. + #include "m-m680x0.h"
  968. + /***************************** OWNERSHIP ***************************
  969. +  *
  970. +  *    Specify owner and group for installed files and programs.
  971. +  *
  972. +  *    The nnmaster will run suid/sgid to this owner and group.
  973. +  *
  974. +  *    The only requirements are that the ownership allows the
  975. +  *    nnmaster to READ the news related files and directories, and
  976. +  *    the ordinary users to read the database and execute the nn*
  977. +  *    programs.
  978. +  *
  979. +  *    Common choices are:  (news, news)  and   (your uid, your gid)
  980. +  */
  981. + #define OWNER    "news"
  982. + #define    GROUP    "news"
  983. + /**************************** LOCALIZATION ****************************
  984. +  *
  985. +  *    Specify where programs and files are installed.
  986. +  *
  987. +  *    BIN_DIRECTORY    - the location of the user programs (mandatory)
  988. +  *
  989. +  *    LIB_DIRECTORY     - the location of auxiliary programs and files.
  990. +  *               (mandatory UNLESS ALL of the following are defined).
  991. +  *
  992. +  *    MASTER_DIRECTORY - the location of the master program (on server)
  993. +  *               (= LIB_DIRECTORY if undefined)
  994. +  *
  995. +  *    CLIENT_DIRECTORY - the location of auxiliary programs (on clients)
  996. +  *               (= LIB_DIRECTORY if undefined)
  997. +  *
  998. +  *    HELP_DIRECTORY   - the location of help files, online manual, etc.
  999. +  *               (= CLIENT_DIRECTORY/help if undefined)
  1000. +  *
  1001. +  *    CACHE_DIRECTORY     - if NNTP is used, nn uses this central directory
  1002. +  *               to store working copies of articles on the local
  1003. +  *               system.  If not defined, it stores the articles
  1004. +  *               in each user's ~/.nn directory.
  1005. +  *
  1006. +  *    TMP_DIRECTORY    - temporary file storage.  Overriden by $TMPDIR.
  1007. +  *               (= /usr/tmp if undefined).
  1008. +  *
  1009. +  *    LOG_FILE         - the location of nn's log file.
  1010. +  *               (= LIB_DIRECTORY/Log if undefined).
  1011. +  */
  1012. + #define BIN_DIRECTORY    "NN:nnlib"
  1013. + #define LIB_DIRECTORY    "NN:nnlib"
  1014. + /**************************** DATABASE LOCATION **************************
  1015. +  *
  1016. +  *    Specify where the nn database should be installed.
  1017. +  *
  1018. +  *    If none of the following symbols are defined, the database will
  1019. +  *    be contained in the NEWS_DIRECTORY in a separate .nn directory for
  1020. +  *    master files and in files named .nnx and .nnd in each group's
  1021. +  *    spool directory.  To use this scheme, the OWNER specified above
  1022. +  *    must have write permission on the news spool directories.
  1023. +  *
  1024. +  *    If you access news via NNTP, you will probably always have to
  1025. +  *    give the database directory explicitly through DB_DIRECTORY
  1026. +  *    (and DB_DATA_DIRECTORY), since the normal news spool directories 
  1027. +  *    are probably not available on the local system.
  1028. +  *    The exception may be if nnmaster runs directly on the nntp server.
  1029. +  -
  1030. +  *
  1031. +  *    To change the default behaviour, you can define the following
  1032. +  *    symbols:
  1033. +  *
  1034. +  *    DB_DIRECTORY       - the directory containing the master files.
  1035. +  *
  1036. +  *    DB_DATA_DIRECTORY  - the directory containing the per-group files
  1037. +  *                 (default is DB_DIRECTORY/DATA if undefined).
  1038. +  *
  1039. +  *    DB_LONG_NAMES       - use group's name rather than number when
  1040. +  *                 building file names in DB_DATA_DIRECTORY.
  1041. +  *         (The file system must support long file names!!)
  1042. +  */
  1043. + /* #define DB_DIRECTORY    "/usr/spool/nn-6.4" */
  1044. + #define DB_DIRECTORY    "NN:nndbase"
  1045. + /*************************** NEWS TRANSPORT **************************
  1046. +  *
  1047. +  *    Specify the location of your news programs and files
  1048. +  *    You only need to specify these if you are not
  1049. +  *    satisfied with the default settings.
  1050. +  *
  1051. +  *    NEWS_DIRECTORY         - The news spool directory.
  1052. +  *                  Default: /usr/spool/news
  1053. +  *
  1054. +  *    NEWS_LIB_DIRECTORY    - The news lib directory.
  1055. +  *                  Default: /usr/lib/news
  1056. +  *
  1057. +  *    INEWS_PATH        - The location of the inews program.
  1058. +  *                  Default: NEWS_LIB_DIR/inews
  1059. +  *
  1060. +  *    RMGROUP_PATH        - The location of the rmgroup program.
  1061. +  *                  Default: NEWS_LIB_DIR/{rm,del}group
  1062. +  */
  1063. + #define NEWS_DIRECTORY        "UUCP:news"    /* */
  1064. + #define NEWS_LIB_DIRECTORY    "UUCP:lib/news"    /* */
  1065. + #define INEWS_PATH        "relaynews"
  1066. + /*************************** MAIL INTERFACE *************************
  1067. +  *
  1068. +  *    Specify a mailer that accepts a letter WITH a header IN THE TEXT.
  1069. +  *
  1070. +  *     A program named 'recmail' program is normally delivered with
  1071. +  *    the Bnews system, or you can use sendmail -t if you have it.
  1072. +  *
  1073. +  *    The contrib/ directory contains two programs which you might
  1074. +  *    be able to use with a little tweaking.
  1075. +  */
  1076. + /* #define REC_MAIL    "/usr/lib/news/recmail"    /* non-sendmail */
  1077. + #define REC_MAIL    "sendmail"    /* sendmail */
  1078. + /*
  1079. +  *    Define HAVE_ROUTING if your mailer understands domain based
  1080. +  *    adresses (...@...) and performs the necessary rerouting (e.g.
  1081. +  *    Sendmail or Smail).
  1082. +  *
  1083. +  *    Otherwise, nn will provide a simple routing facility using
  1084. +  *      routing information specified in the file LIB_DIRECTORY/routes.
  1085. +  */
  1086. + #define HAVE_ROUTING            /* */
  1087. + /*
  1088. +  *    If HAVE_ROUTING is NOT defined, nn needs to know the name of
  1089. +  *     your host.  To obtain the host name it will use either of the
  1090. +  *    'uname' or 'gethostname' system calls as specified in the s-
  1091. +  *    file included above.
  1092. +  *
  1093. +  *    If neither 'uname' nor 'gethostname' is available, you must
  1094. +  *    define HOSTNAME to be the name of your host.  Otherwise, leave
  1095. +  *    it undefined (it will not be used anyway).
  1096. +  */
  1097. + /* #define HOSTNAME    "myhost"    /* Not used if HAVE_ROUTING */
  1098. + /*
  1099. +  *    Define APPEND_SIGNATURE if you want nn to ask users to append
  1100. +  *    ~/.signature to mail messages (reply/forward/mail).
  1101. +  *
  1102. +  *    If the mailer defined in REC_MAIL automatically includes .signature
  1103. +  *    you should not define this (it will fool people to include it twice).
  1104. +  *
  1105. +  *    I think 'recmail' includes .signature, but 'sendmail -t' doesn't.
  1106. +  */
  1107. + #define APPEND_SIGNATURE        /* */
  1108. + /*
  1109. +  *    BUG_REPORT_ADDRESS is the initial value of the bug-report-address
  1110. +  *    variable which is used by the :bug command to report bugs in
  1111. +  *    the nn software.
  1112. +  */
  1113. + #define BUG_REPORT_ADDRESS    "news"
  1114. + /*************************** DOCUMENTATION ***************************
  1115. +  *
  1116. +  *     Specify directories for the user and system manuals
  1117. +  *
  1118. +  *     Adapt this to your local standards; the manuals will be named
  1119. +  *         $(MAN_DIR)/program.$(MAN_SECTION)
  1120. +  *
  1121. +  *    USER_MAN    - nn, nntidy, nngrep, etc.
  1122. +  *    SYS_MAN        - nnadmin
  1123. +  *    DAEMON_MAN    - nnmaster
  1124. +  */
  1125. + #define USER_MAN_DIR     "usr:local/man/man1"
  1126. + #define USER_MAN_SECTION     "1"
  1127. + #define SYS_MAN_DIR     "usr:local/man/man1"
  1128. + #define SYS_MAN_SECTION     "1m"
  1129. + #define DAEMON_MAN_DIR     "usr:local/man/man8"
  1130. + #define DAEMON_MAN_SECTION     "8"
  1131. + /************************** LOCAL POLICY *****************************
  1132. +  *
  1133. +  *    Define STATISTICS if you want to keep a record of how much
  1134. +  *    time the users spend on news reading.
  1135. +  *
  1136. +  *    Sessions shorter than the specified number of minutes are not
  1137. +  *    recorded (don't clutter up the log file).
  1138. +  *
  1139. +  *    Usage statistics is entered into the $LOG_FILE with code U
  1140. +  */
  1141. + /* #define STATISTICS    5 /* minutes */
  1142. + /*
  1143. +  *    Define ACCOUNTING if you want to keep accumulated accounting
  1144. +  *    based on the statistics in a separate 'acct' file.  In this
  1145. +  *    case, the accounting figures will be secret, and not be
  1146. +  *    written to the Log file.  And the users will not be able to
  1147. +  *    "decrease" their own account.
  1148. +  *
  1149. +  *    See account.c for optional cost calculation parameters.
  1150. +  */
  1151. + /* #define ACCOUNTING        /* */
  1152. + /*
  1153. +  *    Define AUTHORIZE if you want to restrict the use of nn to
  1154. +  *    certain users or certain periods of the day.  Define both
  1155. +  *    this and ACCOUNTING if you want to impose a usage quota
  1156. +  *
  1157. +  *    See account.c for implementing various access policies.
  1158. +  */
  1159. + /* #define AUTHORIZE    /* */
  1160. + /*
  1161. +  *    Default folder directory
  1162. +  */
  1163. + #define FOLDER_DIRECTORY    "NNSAVE:"
  1164. + /*
  1165. +  *    Max length of authors name (in "edited" format).
  1166. +  *    Also size of "Name" field on the article menus.
  1167. +  *    You may want to increase this if your terminals are wider than
  1168. +  *    80 columns.
  1169. +  */
  1170. + #define NAME_LENGTH         16
  1171. + /************************ CONFIGURATION COMPLETED ************************/
  1172. + #include "global.h"
  1173. diff -c +recursive +new-file nn-6.4.16/db.c ann/db.c
  1174. *** nn-6.4.16/db.c    Fri Oct 12 22:44:00 1984
  1175. --- ann/db.c    Thu Mar 27 17:58:03 1985
  1176. ***************
  1177. *** 8,13 ****
  1178. --- 8,17 ----
  1179.   #include "db.h"
  1180.   #include <errno.h>
  1181.   
  1182. + #ifdef    AMIGA
  1183. + extern FILE    *debugfh;
  1184. + #endif
  1185.   import char
  1186.       *master_directory, *db_directory, *db_data_directory, *news_directory;
  1187.   import int db_data_subdirs;
  1188. ***************
  1189. *** 90,104 ****
  1190.           if (chdir(news_directory) < 0)
  1191.           sys_error(news_directory);
  1192.   
  1193. !         if (chdir(group_path_name) < 0)
  1194.           return 0;
  1195.       }
  1196.       group_file_name = group_path_name;
  1197.       return 1;
  1198.       }
  1199.   
  1200.       /* client */
  1201. !     if (gh->master_flag & M_NO_DIRECTORY) return 0;
  1202.   
  1203.       if (check_group_access && !use_nntp) {
  1204.       *p = NUL;
  1205. --- 94,111 ----
  1206.           if (chdir(news_directory) < 0)
  1207.           sys_error(news_directory);
  1208.   
  1209. !         if (chdir(group_path_name) < 0){
  1210.           return 0;
  1211.       }
  1212. +     }
  1213.       group_file_name = group_path_name;
  1214.       return 1;
  1215.       }
  1216.   
  1217.       /* client */
  1218. !     if (gh->master_flag & M_NO_DIRECTORY) {
  1219. !         return 0;
  1220. !     }
  1221.   
  1222.       if (check_group_access && !use_nntp) {
  1223.       *p = NUL;
  1224. ***************
  1225. *** 466,471 ****
  1226. --- 473,480 ----
  1227.   #else
  1228.       Loop_Groups_Header(gh) {
  1229.   #endif
  1230.       gh->group_num = l_g_index;
  1231.       db_read_group(gh);
  1232.       db_parse_group(gh, trust_master);
  1233. ***************
  1234. *** 668,673 ****
  1235. --- 677,684 ----
  1236.           char *s;
  1237.           s = strrchr(data_file, '/');
  1238.           *s = NUL;
  1239.           if (!file_exist(data_file, "dx")) {
  1240.           if (mkdir(data_file, 0755) < 0)
  1241.               sys_error("Cannot create directory %s", data_file);
  1242. ***************
  1243. *** 858,863 ****
  1244. --- 869,875 ----
  1245.       buf[6] = gh->first_a_article;
  1246.       buf[7] = gh->last_a_article;
  1247.       buf[8] = gh->creation_time;
  1248.   
  1249.       host_to_net(buf, GROUP_FIELDS);
  1250.       if (fwrite((char *)buf, sizeof(net_long), GROUP_FIELDS, master_file) != GROUP_FIELDS)
  1251. diff -c +recursive +new-file nn-6.4.16/debug.c ann/debug.c
  1252. *** nn-6.4.16/debug.c
  1253. --- ann/debug.c    Wed Mar 05 10:22:17 1985
  1254. ***************
  1255. *** 0 ****
  1256. --- 1,56 ----
  1257. + #include <stdio.h>
  1258. + extern    FILE    *debugfh;
  1259. + FILE    *debug_fopen(name,arg)
  1260. + char    *name;
  1261. + char    *arg;
  1262. + {
  1263. +     return(fopen(name,arg));
  1264. + }
  1265. + FILE    *debug_popen(name,arg)
  1266. + char    *name;
  1267. + char    *arg;
  1268. + {
  1269. +     return(popen(name,arg));
  1270. + }
  1271. + int    debug_open(name,mode)
  1272. + char    *name;
  1273. + int    mode;
  1274. + {
  1275. +     return(open(name,mode));
  1276. + }
  1277. + int    debug_stat(name,st)
  1278. + char    *name;
  1279. + struct    stat    *st;
  1280. + {
  1281. +     return(stat(name,st));
  1282. + }
  1283. + int    debug_system(name)
  1284. + char    *name;
  1285. + {
  1286. +     fprintf(debugfh,"\033[1msystem(%s)\033[0m\n",name);
  1287. +     return(system(name));
  1288. + }
  1289. + void    debug_sys_error(str)
  1290. + char    *str;
  1291. + {
  1292. +     
  1293. +     return(sys_error(str));
  1294. + }
  1295. diff -c +recursive +new-file nn-6.4.16/execute.c ann/execute.c
  1296. *** nn-6.4.16/execute.c    Fri Oct 12 22:44:00 1984
  1297. --- ann/execute.c    Fri Mar 28 11:03:27 1985
  1298. ***************
  1299. *** 9,14 ****
  1300. --- 9,18 ----
  1301.   #include "config.h"
  1302.   #include "term.h"
  1303.   
  1304. + #ifdef    AMIGA
  1305. + extern    FILE    *debugfh;
  1306. + #endif
  1307.   export int shell_restrictions = 0;    /* disable shell escapes */
  1308.   
  1309.   export char *init_shell = SHELL;
  1310. ***************
  1311. *** 41,47 ****
  1312. --- 45,55 ----
  1313.   
  1314.       was_raw = toggle_visual ? visual_off() : unset_raw();
  1315.   
  1316. + #ifdef    AMIGA
  1317. +     pid=0;
  1318. + #else
  1319.       while ((pid = fork()) == -1) sleep(1);
  1320. + #endif
  1321.   
  1322.       if (pid == 0) {
  1323.       for (i = 3 ; i < 20 ; i++)
  1324. ***************
  1325. *** 49,71 ****
  1326.   
  1327.       if (exec_chdir_to != NULL) chdir(exec_chdir_to);
  1328.   
  1329.       execv(path, args);
  1330.   
  1331.       fprintf(stderr, "%s: not found\n", path);
  1332.       nn_exit(20);
  1333. !     }
  1334.       quit = signal(SIGQUIT, SIG_IGN);
  1335.       intr = signal(SIGINT,  SIG_IGN);
  1336.   #ifdef HAVE_JOBCONTROL
  1337.       tstp = signal(SIGTSTP, SIG_DFL);
  1338.   #endif
  1339.       while ((i = wait(&status)) != pid && (i != -1 || errno == EINTR));
  1340.   
  1341.       signal(SIGQUIT, quit);
  1342.       signal(SIGINT,  intr);
  1343.   #ifdef HAVE_JOBCONTROL
  1344.       signal(SIGTSTP, tstp);
  1345.   #endif
  1346.       if (toggle_visual) {
  1347.       visual_on();
  1348.       if (toggle_visual == 2) s_redraw++;
  1349. --- 57,101 ----
  1350.   
  1351.       if (exec_chdir_to != NULL) chdir(exec_chdir_to);
  1352.   
  1353. + #ifdef    AMIGA
  1354. + {
  1355. +     int    i;
  1356. +     char    combuf[200];
  1357. +     strcpy(combuf,path);
  1358. +     for(i=1;args[i]!=NULL;i++){
  1359. +         strcat(combuf," ");
  1360. +         strcat(combuf,args[i]);
  1361. +     }
  1362. +     
  1363. +     
  1364. +     status=system(combuf);
  1365. + }
  1366. +     }    /* pid==0 */
  1367. + #else
  1368.       execv(path, args);
  1369.   
  1370.       fprintf(stderr, "%s: not found\n", path);
  1371.       nn_exit(20);
  1372. !     }    /* pid==0 */
  1373.       quit = signal(SIGQUIT, SIG_IGN);
  1374.       intr = signal(SIGINT,  SIG_IGN);
  1375.   #ifdef HAVE_JOBCONTROL
  1376.       tstp = signal(SIGTSTP, SIG_DFL);
  1377.   #endif
  1378.       while ((i = wait(&status)) != pid && (i != -1 || errno == EINTR));
  1379.   
  1380. + #endif    /* AMIGA */
  1381.       signal(SIGQUIT, quit);
  1382.       signal(SIGINT,  intr);
  1383.   #ifdef HAVE_JOBCONTROL
  1384.       signal(SIGTSTP, tstp);
  1385.   #endif
  1386.       if (toggle_visual) {
  1387.       visual_on();
  1388.       if (toggle_visual == 2) s_redraw++;
  1389. ***************
  1390. *** 72,79 ****
  1391.       }
  1392.   
  1393.       if (was_raw) raw();
  1394.       return (status & 0xff) ? 0x100 : (status >> 8);
  1395.   }
  1396.   
  1397.   
  1398. --- 102,113 ----
  1399.       }
  1400.   
  1401.       if (was_raw) raw();
  1402. !     
  1403. ! #ifdef AMIGA
  1404. !     return status;
  1405. ! #else
  1406.       return (status & 0xff) ? 0x100 : (status >> 8);
  1407. + #endif
  1408.   }
  1409.   
  1410.   
  1411. diff -c +recursive +new-file nn-6.4.16/expire.c ann/expire.c
  1412. *** nn-6.4.16/expire.c    Fri Oct 12 22:44:00 1984
  1413. --- ann/expire.c    Thu Mar 27 18:01:10 1985
  1414. ***************
  1415. *** 11,16 ****
  1416. --- 11,20 ----
  1417.   #include "db.h"
  1418.   #include "dir.h"
  1419.   
  1420. + #ifdef    AMIGA
  1421. + extern    FILE    *debugfh;
  1422. + #endif
  1423.   import int trace, debug_mode;
  1424.   import int nntp_failed;
  1425.   
  1426. ***************
  1427. *** 597,602 ****
  1428. --- 601,607 ----
  1429.       log_entry('X', "Expire: %ld art, %d gr, %ld s",
  1430.             exp_article_count, exp_group_count,
  1431.             (long)(cur_time() - start_time));
  1432.   
  1433.       return temp >= 0;
  1434.   }
  1435. diff -c +recursive +new-file nn-6.4.16/folder.c ann/folder.c
  1436. *** nn-6.4.16/folder.c    Fri Oct 12 22:44:00 1984
  1437. --- ann/folder.c    Fri Mar 07 19:14:38 1985
  1438. ***************
  1439. *** 91,97 ****
  1440. --- 91,101 ----
  1441.           if (folder_directory == NULL) {
  1442.               if (!(cp = getenv("FOLDER")))
  1443.               cp = FOLDER_DIRECTORY;
  1444. + #ifndef AMIGA
  1445.               folder_directory = home_relative(cp);
  1446. + #else
  1447. +             folder_directory = cp;
  1448. + #endif
  1449.           }
  1450.   
  1451.           cp = folder_directory;
  1452. ***************
  1453. *** 105,111 ****
  1454. --- 109,119 ----
  1455.   
  1456.            cp_str:
  1457.           while (*cp) *dp++ = *cp++;
  1458. + #ifndef AMIGA
  1459.           if (dp[-1] != '/') *dp++ = '/';
  1460. + #else
  1461. +         if (dp[-1] != '/' && dp[-1] != ':' ) *dp++ = '/';
  1462. + #endif
  1463.           goto no_parse;
  1464.           }
  1465.   
  1466. diff -c +recursive +new-file nn-6.4.16/fullname.c ann/fullname.c
  1467. *** nn-6.4.16/fullname.c    Fri Oct 12 22:44:00 1984
  1468. --- ann/fullname.c    Wed Mar 05 10:03:03 1985
  1469. ***************
  1470. *** 89,96 ****
  1471.   {
  1472.       static char *fullname = NULL;
  1473.       char inbuf[FILENAME];
  1474.       struct passwd *pw, *getpwuid();
  1475.       if (fullname == NULL) {
  1476.       if ((fullname = getenv("NAME")) != NULL)
  1477.           return fullname;
  1478. --- 89,99 ----
  1479.   {
  1480.       static char *fullname = NULL;
  1481.       char inbuf[FILENAME];
  1482. + #ifdef AZTEC
  1483. +     struct passwd *pw;
  1484. + #else
  1485.       struct passwd *pw, *getpwuid();
  1486. ! #endif
  1487.       if (fullname == NULL) {
  1488.       if ((fullname = getenv("NAME")) != NULL)
  1489.           return fullname;
  1490. diff -c +recursive +new-file nn-6.4.16/global.c ann/global.c
  1491. *** nn-6.4.16/global.c    Fri Oct 12 22:44:00 1984
  1492. --- ann/global.c    Thu Mar 27 18:03:38 1985
  1493. ***************
  1494. *** 10,15 ****
  1495. --- 10,24 ----
  1496.   #include "config.h"
  1497.   #include "patchlevel.h"
  1498.   
  1499. + #ifdef    AMIGA
  1500. + #define    FALSE    0L
  1501. + #include "readconfig.h"
  1502. + #endif
  1503. + #ifdef    AMIGA
  1504. + extern    FILE    *debugfh;
  1505. + #endif
  1506.   export char *home_directory;
  1507.   export char *nn_directory;        /* ~/.nn */
  1508.   export char *news_directory;        /* /usr/spool/news */
  1509. ***************
  1510. *** 33,39 ****
  1511.   export char *temp_file;
  1512.   
  1513.   #ifndef TMP_DIRECTORY
  1514. ! #define TMP_DIRECTORY "/usr/tmp"
  1515.   #endif
  1516.   export char *tmp_directory = TMP_DIRECTORY;
  1517.   
  1518. --- 42,52 ----
  1519.   export char *temp_file;
  1520.   
  1521.   #ifndef TMP_DIRECTORY
  1522. ! #ifdef AMIGA
  1523. ! #define TMP_DIRECTORY "t:"
  1524. ! #else
  1525. ! #define TMP_DIRECTORY "/tmp"
  1526. ! #endif /* AMIGA */
  1527.   #endif
  1528.   export char *tmp_directory = TMP_DIRECTORY;
  1529.   
  1530. ***************
  1531. *** 229,234 ****
  1532. --- 242,249 ----
  1533.       db_data_directory = NULL;
  1534.   #endif
  1535.   #endif
  1536.   #ifndef DB_LONG_NAMES
  1537.       if (db_data_directory != NULL)
  1538.       db_data_subdirs = file_exist(relative(db_data_directory, "0"), "dx");
  1539. ***************
  1540. *** 270,277 ****
  1541. --- 285,297 ----
  1542.       signal(SIGTSTP, catch_suspend);
  1543.   #endif
  1544.   
  1545. + #ifndef AMIGA
  1546.       if ((home_directory = getenv("HOME")) == NULL)
  1547.       user_error("No HOME environment variable");
  1548. + #else
  1549. +     if ((home_directory = getenv("HOME")) == NULL)
  1550. +     home_directory="NNHOME:";
  1551. + #endif
  1552.   
  1553.       if ((pager = getenv("PAGER")) == NULL)
  1554.       pager = DEFAULT_PAGER;
  1555. ***************
  1556. *** 299,305 ****
  1557. --- 319,334 ----
  1558.       else
  1559.           tmp_directory = temp_dir;
  1560.   
  1561. + #ifdef    AMIGA
  1562. +     if(tmp_directory[strlen(tmp_directory)-1]==':'){
  1563. +         sprintf(buf, "%snn.XXXXXX", tmp_directory);
  1564. +     }
  1565. +     else{
  1566. +         sprintf(buf, "%s/nn.XXXXXX", tmp_directory);
  1567. +     }
  1568. + #else
  1569.       sprintf(buf, "%s/nn.XXXXXX", tmp_directory);
  1570. + #endif
  1571.       mktemp(buf);
  1572.       temp_file = buf;
  1573.   }
  1574. ***************
  1575. *** 425,431 ****
  1576. --- 454,470 ----
  1577.   {
  1578.       static char concat_path[FILENAME];
  1579.   
  1580. + #ifdef AMIGA
  1581. +     if(dir[strlen(dir)-1]==':'){
  1582. +         sprintf(concat_path,"%s%s",dir,name);
  1583. +     }
  1584. +     else{
  1585. +         sprintf(concat_path,"%s/%s",dir,name);
  1586. +     }
  1587. + #else
  1588.       sprintf(concat_path, "%s/%s", dir, name);
  1589. + #endif
  1590.       return concat_path;
  1591.   }
  1592.   
  1593. ***************
  1594. *** 436,442 ****
  1595. --- 475,491 ----
  1596.       char *buf;
  1597.   
  1598.       buf = newstr(strlen(dir) + strlen(name) + 2);
  1599. + #ifdef AMIGA
  1600. +     if(dir[strlen(dir)-1]==':'){
  1601. +         sprintf(buf,"%s%s",dir,name);
  1602. +     }
  1603. +     else{
  1604. +         sprintf(buf,"%s/%s",dir,name);
  1605. +     }
  1606. + #else
  1607.       sprintf(buf, "%s/%s", dir, name);
  1608. + #endif
  1609.   
  1610.       return buf;
  1611.   }
  1612. ***************
  1613. *** 821,827 ****
  1614. --- 870,880 ----
  1615.   char *user_name()
  1616.   {
  1617.       static char *user = NULL;
  1618. + #ifdef AZTEC
  1619. +     struct passwd *pw;
  1620. + #else
  1621.       struct passwd *pw, *getpwuid();
  1622. + #endif
  1623.       extern char *getlogin(), *getenv();
  1624.   
  1625.       if (who_am_i == I_AM_MASTER) return "M";
  1626. ***************
  1627. *** 828,834 ****
  1628. --- 881,901 ----
  1629.       if (who_am_i == I_AM_EXPIRE) return "X";
  1630.   
  1631.       if (user == NULL) {
  1632. + #ifdef    AMIGA
  1633. + {
  1634. + struct    uuconfig    conf;
  1635. +     if(readconfig("uulib:config",&conf)==FALSE){
  1636. +         user=getlogin();    /* returns 'amiga' */
  1637. +     }
  1638. +     else{
  1639. +         user=malloc(200);
  1640. +         strncpy(user,&(conf.UserName),200);
  1641. +     }
  1642. + }
  1643. + #else
  1644.       user = getlogin();
  1645. + #endif
  1646.       if (user != NULL && *user != NUL) goto out;
  1647.   
  1648.       pw = getpwuid((int)user_id);
  1649. diff -c +recursive +new-file nn-6.4.16/group.c ann/group.c
  1650. *** nn-6.4.16/group.c    Fri Oct 12 22:44:00 1984
  1651. --- ann/group.c    Thu Mar 27 18:05:13 1985
  1652. ***************
  1653. *** 15,20 ****
  1654. --- 15,24 ----
  1655.   #include <syslog.h>
  1656.   #endif
  1657.   
  1658. + #ifdef    AMIGA
  1659. + extern    FILE    *debugfh;
  1660. + #endif
  1661.   export int  dont_split_digests = 0;
  1662.   export int  dont_sort_articles = 0;
  1663.   export int  also_cross_postings = 0;
  1664. ***************
  1665. *** 468,474 ****
  1666.       
  1667.       mask = NULL;
  1668.       if (access_mode == 0) access_mode |= ACC_PARSE_VARIABLES;
  1669. !     
  1670.       if (command == K_GOTO_GROUP)
  1671.       goto get_group_name;
  1672.   
  1673. --- 472,478 ----
  1674.       
  1675.       mask = NULL;
  1676.       if (access_mode == 0) access_mode |= ACC_PARSE_VARIABLES;
  1677.       if (command == K_GOTO_GROUP)
  1678.       goto get_group_name;
  1679.   
  1680. ***************
  1681. *** 481,486 ****
  1682. --- 485,491 ----
  1683.       if (gh == NULL)
  1684.           goto_return(ME_NO_REDRAW);
  1685.   
  1686.       if (gh->first_db_article < gh->last_db_article && gh->current_first <= 0) {
  1687.           sprintf(buffer, "%s%s%s) ",
  1688.              (gh->group_flag & G_UNSUBSCRIBED) ? " UNSUB" : "",
  1689. ***************
  1690. *** 784,792 ****
  1691.   
  1692.    more_articles:
  1693.       if (first > gh->last_db_article) goto_return(ME_NO_REDRAW);
  1694.       if (gh != orig_group) goto enter_new_level;
  1695.       if (!only_unread_articles && gh->current_first <= gh->first_db_article) {
  1696.       msg("No extra articles");
  1697.       goto_return(ME_NO_REDRAW);
  1698. --- 789,795 ----
  1699. ***************
  1700. *** 917,923 ****
  1701.   
  1702.       Loop_Groups_Sequence(gh) {
  1703.       if (gh->group_flag & G_FOLDER) continue;
  1704. !     if (gh->master_flag & M_NO_DIRECTORY) continue;
  1705.       if ((gh->group_flag & G_UNSUBSCRIBED) && !also_unsub_groups)
  1706.           continue;
  1707.       if (!also_read_articles && gh->last_article >= gh->last_db_article)
  1708. --- 920,928 ----
  1709.   
  1710.       Loop_Groups_Sequence(gh) {
  1711.       if (gh->group_flag & G_FOLDER) continue;
  1712. !     if (gh->master_flag & M_NO_DIRECTORY) {
  1713. !         continue;
  1714. !     }
  1715.       if ((gh->group_flag & G_UNSUBSCRIBED) && !also_unsub_groups)
  1716.           continue;
  1717.       if (!also_read_articles && gh->last_article >= gh->last_db_article)
  1718. ***************
  1719. *** 934,940 ****
  1720.           continue;
  1721.       }
  1722.   
  1723. !     if (gh->master_flag & M_NO_DIRECTORY) continue;
  1724.       if ((gh->group_flag & G_UNSUBSCRIBED) && !also_unsub_groups)
  1725.           continue;
  1726.   
  1727. --- 939,947 ----
  1728.           continue;
  1729.       }
  1730.   
  1731. !     if (gh->master_flag & M_NO_DIRECTORY) {
  1732. !         continue;
  1733. !     }
  1734.       if ((gh->group_flag & G_UNSUBSCRIBED) && !also_unsub_groups)
  1735.           continue;
  1736.   
  1737. ***************
  1738. *** 1063,1069 ****
  1739.       if (amount < 0) {
  1740.       Loop_Groups_Sequence(gh) {
  1741.           if (gh->group_flag & G_FAKED) continue;
  1742. !         if (gh->master_flag & M_NO_DIRECTORY) continue;
  1743.           if (gh != current_group) {
  1744.           if (gh->unread_count <= 0) continue;
  1745.           if (gh->group_flag & G_UNSUBSCRIBED && !also_unsub_groups)
  1746. --- 1070,1078 ----
  1747.       if (amount < 0) {
  1748.       Loop_Groups_Sequence(gh) {
  1749.           if (gh->group_flag & G_FAKED) continue;
  1750. !         if (gh->master_flag & M_NO_DIRECTORY) {
  1751. !             continue;
  1752. !         }
  1753.           if (gh != current_group) {
  1754.           if (gh->unread_count <= 0) continue;
  1755.           if (gh->group_flag & G_UNSUBSCRIBED && !also_unsub_groups)
  1756. ***************
  1757. *** 1073,1079 ****
  1758.       }
  1759.       } else
  1760.       Loop_Groups_Sorted(gh) {
  1761. !     if (gh->master_flag & (M_NO_DIRECTORY | M_IGNORE_GROUP)) continue;
  1762.       if (amount <= 1 && gh->unread_count <= 0) continue;
  1763.       if (amount == 0 && (gh->group_flag & G_UNSUBSCRIBED)) continue;
  1764.       if (amount == 3 && (gh->group_flag & G_UNSUBSCRIBED) == 0) continue;
  1765. --- 1082,1090 ----
  1766.       }
  1767.       } else
  1768.       Loop_Groups_Sorted(gh) {
  1769. !     if (gh->master_flag & (M_NO_DIRECTORY | M_IGNORE_GROUP)){
  1770. !          continue;
  1771. !     }
  1772.       if (amount <= 1 && gh->unread_count <= 0) continue;
  1773.       if (amount == 0 && (gh->group_flag & G_UNSUBSCRIBED)) continue;
  1774.       if (amount == 3 && (gh->group_flag & G_UNSUBSCRIBED) == 0) continue;
  1775. diff -c +recursive +new-file nn-6.4.16/makefile.amiga ann/makefile.amiga
  1776. *** nn-6.4.16/makefile.amiga
  1777. --- ann/makefile.amiga    Fri Mar 28 10:02:45 1985
  1778. ***************
  1779. *** 0 ****
  1780. --- 1,160 ----
  1781. + CC =     bin:gcc
  1782. + CPP =     bin:kcc -E
  1783. + AMIGA_INCLUDE = -Iwork:src/aztec/include13
  1784. + CFLAGS = -Iconf $(AMIGA_INCLUDE) -DAMIGA -DPATCH17 -DPATCH18
  1785. + LDFLAGS = -s
  1786. + BIN_PROG =    nn  nnusage nngrab nnstats nnacct
  1787. + BIN_LINK =    nncheck nnadmin nntidy nngoback nngrep nnpost nnbatch
  1788. + LIB_PROG =    aux upgrade_rc
  1789. + MASTER_PROG =    nnmaster back_act nnspew
  1790. + SHELL = /bin/sh
  1791. + MASTER = master.o collect.o expire.o proto.o hostname.o \
  1792. +     global.o options.o active.o db.o nntp.o \
  1793. +     pack_date.o pack_name.o pack_subject.o news.o digest.o
  1794. + NN =     nn.o admin.o proto.o global.o options.o db.o nntp.o \
  1795. +     init.o variable.o term.o keymap.o macro.o regexp.o \
  1796. +     menu.o more.o newsrc.o group.o folder.o dir.o \
  1797. +     sort.o articles.o sequence.o kill.o active.o fullname.o \
  1798. +     answer.o reroute.o hostname.o save.o unshar.o decode.o execute.o \
  1799. +     pack_date.o pack_name.o pack_subject.o news.o digest.o match.o
  1800. + ACCT = account.o global.o options.o proto.o hostname.o 
  1801. + MAIL = nnmail.o reroute.o hostname.o global.o options.o
  1802. + # all:    $(BIN_PROG) $(LIB_PROG) $(MASTER_PROG) inst
  1803. + all: nn nnmaster simplenews amiga-aux
  1804. + copyit: nn nnmaster simplenews amiga-aux
  1805. +     copy nn dh1:uucpplus/nnlib/nn
  1806. +     copy nnmaster dh1:uucpplus/nnlib/nnmaster
  1807. +     copy nn dh1:uucpplus/nnlib/nnadmin
  1808. +     copy amiga-aux dh1:uucpplus/nnlib/amiga-aux
  1809. +     copy simplenews dh1:uucpplus/nnlib/simplenews
  1810. +     copy amiga-back-act    dh1:uucpplus/nnlib/amiga-back-act
  1811. + simplenews: simplenews.o readconfig.o
  1812. +     $(CC) -o simplenews simplenews.o readconfig.o $(CFLAGS) $(LDFLAGS)
  1813. + simplenews.o: simplenews.c    readconfig.h readconfig.c
  1814. + readconfig.o: readconfig.c readconfig.h
  1815. + amiga-aux: amiga-aux.o readconfig.o
  1816. +     $(CC) -o amiga-aux amiga-aux.o readconfig.o $(CFLAGS) $(LDFLAGS)
  1817. + amiga-aux.o: amiga-aux.c
  1818. + # debug: debug.o
  1819. + # debug.o: debug.c
  1820. + client: $(BIN_PROG) $(LIB_PROG) inst
  1821. + master: $(MASTER_PROG) inst
  1822. + nn:     $(NN) readconfig.o
  1823. +     echo "linking nn"
  1824. +     $(CC) -o nn $(NN) readconfig.o $(CFLAGS) $(LDFLAGS) gcc:c/heapmem.o -ltermcap -lamy -lc
  1825. + nnmaster:  $(MASTER) readconfig.o
  1826. +     echo "linking nnmaster"
  1827. +     $(CC) -o nnmaster $(CFLAGS) $(MASTER) readconfig.o $(LDFLAGS) 
  1828. + nnmail:     $(MAIL)
  1829. +     echo "linking nnmail"
  1830. +     $(CC) -o nnmail $(CFLAGS) $(MAIL) $(LDFLAGS)
  1831. + nnstats: nnstats.sh prefix
  1832. + #    cat prefix nnstats.sh > nnstats ; chmod +x nnstats
  1833. + nnusage: nnusage.sh prefix
  1834. + #    cat prefix nnusage.sh > nnusage ; chmod +x nnusage
  1835. + nngrab:    nngrab.sh prefix
  1836. + #    cat prefix nngrab.sh > nngrab ; chmod +x nngrab
  1837. + aux:     aux.sh prefix
  1838. + #    cat prefix aux.sh > aux ; chmod +x aux
  1839. + upgrade_rc: upgrade_rc.sh prefix
  1840. + #    cat prefix upgrade_rc.sh > upgrade_rc ; chmod +x upgrade_rc
  1841. + nnacct:  $(ACCT)
  1842. +     echo "linking nnacct"
  1843. +     $(CC) -o nnacct $(CFLAGS) $(ACCT) $(LDFLAGS)
  1844. + back_act: back_act.sh prefix
  1845. + #    cat prefix back_act.sh > back_act ; chmod +x back_act
  1846. + nnspew:    nnspew.sh prefix
  1847. + #    cat prefix nnspew.sh > nnspew ; chmod +x nnspew
  1848. + prefix:    config.h mkprefix
  1849. +     mkprefix >prefix prefix
  1850. + mkprefix:  prefix.o global.o
  1851. +     $(CC) -o mkprefix $(CFLAGS) prefix.o global.o $(LDFLAGS)
  1852. + update.h:    config.h patchlevel.h # Makefile
  1853. + #    sh -c "[ -f update.h ] || (echo 0 > update.h)"
  1854. + #    sh -c "expr `cat update.h` + 1 > update1.h && mv update1.h update.h"
  1855. + #    echo configuration number updated to `cat update.h`
  1856. + cvt-help:     config.h cvt-help.c
  1857. +     $(CC) -o cvt-help cvt-help.c $(LDFLAGS)
  1858. + usercheck:     config.h usercheck.c
  1859. +     $(CC) -o usercheck usercheck.c $(LDFLAGS)
  1860. + inst: config.h xmakefile inst.sh cvt-help usercheck mkprefix man/nn.1
  1861. + #    echo building install script: ./inst
  1862. + #    ./mkprefix full < /dev/null > inst
  1863. + #    echo BIN_PROG=\"$(BIN_PROG)\" >> inst
  1864. + #    echo BIN_LINK=\"$(BIN_LINK)\" >> inst
  1865. + #    echo LIB_PROG=\"$(LIB_PROG)\" >> inst
  1866. + #    echo MASTER_PROG=\"$(MASTER_PROG)\" >> inst
  1867. + #    cat inst.sh >> inst
  1868. + #    chmod 755 inst
  1869. + man/nn.1:    man/nn.1.A man/nn.1.B man/nn.1.C man/nn.1.D
  1870. +     -[ ! -f man/nn.1 ] || mv man/nn.1 man/nn.1~
  1871. +     cat man/nn.1.? > man/nn.1
  1872. + clean:
  1873. +     rm -f $(BIN_PROG) $(LIB_PROG) $(MASTER_PROG) cvt-help usercheck
  1874. +     rm -f prefix mkprefix inst
  1875. +     rm -f man/nn.1 man/nn.1~
  1876. + account.o:    account.c config.h global.h vararg.h options.h proto.h
  1877. + active.o:    active.c config.h global.h vararg.h data.h
  1878. + admin.o:    admin.c config.h global.h vararg.h data.h db.h term.h \
  1879. +         proto.h
  1880. + answer.o:    answer.c config.h global.h vararg.h data.h news.h term.h \
  1881. +         keymap.h options.h
  1882. + articles.o:    articles.c config.h global.h vararg.h data.h db.h articles.h
  1883. + collect.o:    collect.c config.h global.h vararg.h data.h db.h news.h
  1884. + db.o:        db.c config.h global.h vararg.h data.h db.h
  1885. + decode.o:    decode.c config.h global.h vararg.h data.h
  1886. + digest.o:    digest.c config.h global.h vararg.h data.h news.h debug.h
  1887. + dir.o:        dir.c config.h global.h vararg.h data.h articles.h dir.h
  1888. + execute.o:    execute.c config.h global.h vararg.h data.h term.h
  1889. + expire.o:    expire.c config.h global.h vararg.h data.h db.h dir.h
  1890. + folder.o:    folder.c config.h global.h vararg.h data.h articles.h news.h \
  1891. +         term.h menu.h
  1892. + fullname.o:    fullname.c config.h global.h
  1893. + global.o:    global.c config.h global.h vararg.h data.h \
  1894. +         patchlevel.h
  1895. + # update.h
  1896. + group.o:    group.c config.h global.h vararg.h data.h articles.h db.h \
  1897. +         term.h menu.h keymap.h regexp.h
  1898. + hostname.o:    hostname.c config.h
  1899. + init.o:        init.c config.h global.h vararg.h data.h articles.h term.h \
  1900. +         keymap.h menu.h
  1901. + keymap.o:    keymap.c config.h global.h vararg.h data.h keymap.h term.h
  1902. + kill.o:        kill.c config.h global.h vararg.h data.h term.h regexp.h
  1903. + macro.o:    macro.c config.h global.h vararg.h data.h keymap.h term.h
  1904. + master.o:    master.c config.h global.h vararg.h data.h db.h \
  1905. +         options.h proto.h
  1906. + match.o:    match.c config.h global.h regexp.h
  1907. + menu.o:        menu.c config.h global.h vararg.h data.h articles.h term.h \
  1908. +         keymap.h menu.h regexp.h
  1909. + more.o:        more.c config.h global.h vararg.h data.h news.h term.h \
  1910. +         menu.h keymap.h regexp.h
  1911. + news.o:        news.c config.h global.h vararg.h data.h news.h
  1912. + nn.o:        nn.c config.h global.h vararg.h data.h menu.h term.h \
  1913. +         keymap.h options.h articles.h proto.h
  1914. + nnmail.o:    nnmail.c config.h global.h vararg.h data.h options.h
  1915. + nntp.o:        nntp.c config.h global.h vararg.h data.h nntp.h
  1916. + options.o:    options.c config.h global.h vararg.h data.h options.h
  1917. + pack_date.o:    pack_date.c config.h global.h vararg.h data.h
  1918. + pack_name.o:    pack_name.c config.h global.h vararg.h data.h
  1919. + pack_subject.o:    pack_subject.c config.h global.h vararg.h data.h
  1920. + prefix.o:    config.h global.h
  1921. + proto.o:    proto.c config.h global.h proto.h
  1922. + newsrc.o:    newsrc.c config.h global.h vararg.h data.h term.h debug.h
  1923. + regexp.o:    regexp.c config.h global.h vararg.h data.h regexp.h
  1924. + reroute.o:    reroute.c config.h global.h vararg.h data.h
  1925. + save.o:        save.c config.h global.h vararg.h data.h term.h keymap.h \
  1926. +         news.h
  1927. + selection.o:    selection.c config.h global.h vararg.h data.h term.h\
  1928. +          articles.h
  1929. + sequence.o:    sequence.c config.h global.h vararg.h data.h debug.h
  1930. + sort.o:        sort.c config.h global.h vararg.h data.h
  1931. + term.o:        term.c config.h global.h vararg.h data.h term.h keymap.h
  1932. + unshar.o:    unshar.c config.h global.h vararg.h data.h
  1933. + variable.o:    variable.c config.h global.h vararg.h data.h
  1934. + nn1:    $(NN)
  1935. +     $(CC) -o nn1 -Mnn1 $(CFLAGS) $(NN) $(LDFLAGS) -ltermlib 
  1936. + nnmaster1: $(MASTER)
  1937. +     $(CC) -o nnmaster1 -Mnnmaster1 $(CFLAGS) $(MASTER) $(LDFLAGS) 
  1938. + lint:
  1939. +     echo LINTING NN
  1940. +     echo LINTING MASTER
  1941. diff -c +recursive +new-file nn-6.4.16/master.c ann/master.c
  1942. *** nn-6.4.16/master.c    Fri Oct 12 22:44:00 1984
  1943. --- ann/master.c    Thu Mar 27 18:11:12 1985
  1944. ***************
  1945. *** 6,11 ****
  1946. --- 6,15 ----
  1947.    *    maintains the article header database.
  1948.    */
  1949.   
  1950. + /*
  1951. +     modified to work with the Amiga by Alexander Rawass
  1952. + */
  1953.   #include <signal.h>
  1954.   #include <errno.h>
  1955.   #include "config.h"
  1956. ***************
  1957. *** 12,17 ****
  1958. --- 16,25 ----
  1959.   #include "db.h"
  1960.   #include "proto.h"
  1961.   
  1962. + #ifdef    AMIGA
  1963. + FILE    *debugfh;
  1964. + #endif
  1965.   import char *bin_directory;
  1966.   
  1967.   /*
  1968. ***************
  1969. *** 173,178 ****
  1970. --- 181,187 ----
  1971.   static clean_group_internal(gh)    /* no write */
  1972.   register group_header *gh;
  1973.   {
  1974.       gh->first_db_article = 0;
  1975.       gh->last_db_article = 0;
  1976.   
  1977. ***************
  1978. *** 200,205 ****
  1979. --- 209,215 ----
  1980.   
  1981.       clean_group_internal(gh);
  1982.   
  1983.       db_write_group(gh);
  1984.   }
  1985.   
  1986. ***************
  1987. *** 269,274 ****
  1988. --- 279,285 ----
  1989.   {
  1990.       register group_header *gh;
  1991.   
  1992.       if (master.free_groups <= 0)
  1993.       db_expand_master();
  1994.   
  1995. ***************
  1996. *** 358,366 ****
  1997.   
  1998.       sprintf(command, "awk 'NF>0{print $1}' %s | sort | uniq -d", news_active);
  1999.   
  2000.       src = popen(command, "r");
  2001. !     if (src == NULL)
  2002. !     sys_error("popen(%s) failed", command);
  2003.       
  2004.       for (lcount = 0; fgets(groupname, 512, src); lcount++) {
  2005.       if (lcount == 0)
  2006. --- 369,380 ----
  2007.   
  2008.       sprintf(command, "awk 'NF>0{print $1}' %s | sort | uniq -d", news_active);
  2009.   
  2010. + #ifndef AMIGA
  2011.       src = popen(command, "r");
  2012. !     if (src == NULL){
  2013. !         sys_error("popen(%s) failed", command);
  2014. !     }
  2015.       
  2016.       for (lcount = 0; fgets(groupname, 512, src); lcount++) {
  2017.       if (lcount == 0)
  2018. ***************
  2019. *** 372,377 ****
  2020. --- 386,392 ----
  2021.   
  2022.       pclose(src);
  2023.   
  2024.       if (lcount > 0) {
  2025.       printf("Do you want to repair this file before continuing ? (y)");
  2026.       gets(command);
  2027. ***************
  2028. *** 382,387 ****
  2029. --- 397,403 ----
  2030.           nn_exit(0);
  2031.       }
  2032.       }
  2033. + #endif
  2034.   
  2035.       /* if a "GROUPS" file exist offer to use that, else */
  2036.       /* read group names from active file */
  2037. ***************
  2038. *** 403,413 ****
  2039.       fl;
  2040.   
  2041.       if (!use_group_file) {
  2042.       sprintf(command, "awk 'NF>0{print $1}' %s | sort -u", news_active);
  2043.   
  2044.       src = popen(command, "r");
  2045. !     if (src == NULL)
  2046.           sys_error("popen(%s) failed", command);
  2047.       }
  2048.   
  2049.       open_master(OPEN_CREATE);
  2050. --- 419,440 ----
  2051.       fl;
  2052.   
  2053.       if (!use_group_file) {
  2054. + #ifdef AMIGA
  2055. +     sprintf(command,"c:type %s",news_active);
  2056. + #else
  2057.       sprintf(command, "awk 'NF>0{print $1}' %s | sort -u", news_active);
  2058. + #endif
  2059.   
  2060. + #ifdef    AMIGA
  2061. +     src = fopen(news_active,"r");
  2062. + #else
  2063.       src = popen(command, "r");
  2064. ! #endif
  2065. !     if (src == NULL){
  2066.           sys_error("popen(%s) failed", command);
  2067. +     }
  2068.       }
  2069.   
  2070.       open_master(OPEN_CREATE);
  2071. ***************
  2072. *** 432,439 ****
  2073.           gh->group_name_length = 0;
  2074.           if (db_parse_group(gh, 0) <= 0) break;
  2075.       } else {
  2076.           if (fgets(groupname, 512, src) == NULL) break;
  2077.           gh->group_name_length = strlen(groupname) - 1;    /* strip NL */
  2078.           groupname[gh->group_name_length] = NUL;
  2079.           gh->creation_time = 0;
  2080. --- 459,478 ----
  2081.           gh->group_name_length = 0;
  2082.           if (db_parse_group(gh, 0) <= 0) break;
  2083.       } else {
  2084. + #ifndef AMIGA
  2085.           if (fgets(groupname, 512, src) == NULL) break;
  2086. ! #else
  2087. !         {
  2088. !             char    *gname;
  2089. !             int        i;
  2090. !             
  2091. !             gname=fgets(groupname,512,src);
  2092. !             if(gname==NULL) break;
  2093. !             for(i=0;groupname[i]!=' ';i++) ;    
  2094. !             groupname[i]='\n';
  2095. !             groupname[i+1]=0;
  2096. !         }
  2097. ! #endif
  2098.           gh->group_name_length = strlen(groupname) - 1;    /* strip NL */
  2099.           groupname[gh->group_name_length] = NUL;
  2100.           gh->creation_time = 0;
  2101. ***************
  2102. *** 475,481 ****
  2103. --- 514,524 ----
  2104.       if (use_group_file)
  2105.       close_groups();
  2106.       else
  2107. + #ifdef AMIGA
  2108. +     fclose(src);
  2109. + #else
  2110.       pclose(src);
  2111. + #endif
  2112.   
  2113.       printf("%s %s/GROUPS file\n",
  2114.          use_group_file ? "Updating" : "Building", db_directory);
  2115. ***************
  2116. *** 588,593 ****
  2117. --- 631,640 ----
  2118.       int skip_pass;
  2119.       long pass_no;
  2120.   
  2121. + #ifdef    AMIGA
  2122. +     debugfh=fopen("*","w");
  2123. + #endif
  2124.       umask(002);            /* avoid paranoia */
  2125.   
  2126.       who_am_i = I_AM_MASTER;
  2127. ***************
  2128. *** 687,692 ****
  2129. --- 734,740 ----
  2130.           nn_exit(0);
  2131.       }
  2132.   
  2133.       if (!ignore_lock && master.db_lock[0]) {
  2134.       printf("Database locked (unlock with -l or ignore with -i)\n");
  2135.       nn_exit(88);
  2136. ***************
  2137. *** 704,709 ****
  2138. --- 752,758 ----
  2139.       }
  2140.   
  2141.       if (repeat_delay && !debug_mode && !foreground) {
  2142.       while ((temp = fork()) < 0) sleep(1);
  2143.       if (temp) exit(0);    /* not nn_exit() !!! */
  2144.   
  2145. ***************
  2146. *** 720,725 ****
  2147. --- 769,775 ----
  2148.             repeat_delay, expire_level,
  2149.             expire_once ? "-F " : "", expire_method);
  2150.   
  2151.       if (check_on_startup) {
  2152.       char cmd[FILENAME];
  2153.       sprintf(cmd, "%s/nnadmin Z", bin_directory);
  2154. ***************
  2155. *** 731,738 ****
  2156.   
  2157.       init_digest_parsing();
  2158.   
  2159. -     open_master(OPEN_UPDATE);
  2160.   
  2161.       if (group_selection)
  2162.       set_group_restrictions(argv + 1, group_selection);
  2163.   
  2164. --- 781,788 ----
  2165.   
  2166.       init_digest_parsing();
  2167.   
  2168.   
  2169. +     open_master(OPEN_UPDATE);
  2170.       if (group_selection)
  2171.       set_group_restrictions(argv + 1, group_selection);
  2172.   
  2173. ***************
  2174. *** 800,810 ****
  2175.           continue;
  2176.       }
  2177.   
  2178.       visit_active_file();
  2179.   
  2180. !     if (do_expire())
  2181.           if (!expire_once && do_collect())
  2182.           master.last_scan = age_active;
  2183.   
  2184.       db_write_master();
  2185.   
  2186. --- 850,862 ----
  2187.           continue;
  2188.       }
  2189.   
  2190.       visit_active_file();
  2191.   
  2192. !     if (do_expire()){
  2193.           if (!expire_once && do_collect())
  2194.           master.last_scan = age_active;
  2195. +     }
  2196.   
  2197.       db_write_master();
  2198.   
  2199. ***************
  2200. *** 836,841 ****
  2201. --- 888,894 ----
  2202.       register group_header *gh;
  2203.       FILE *open_gate_file();
  2204.   
  2205.       gate = open_gate_file(OPEN_READ);
  2206.       if (gate == NULL) return 0;
  2207.   
  2208. ***************
  2209. *** 869,874 ****
  2210. --- 922,928 ----
  2211.       log_entry('A', "RECV %c %s %c %ld (%s)",
  2212.             command, gh == NULL ? "(all)" : gh->group_name, opt, arg, user_date);
  2213.   
  2214.       switch (command) {
  2215.   
  2216.        case SM_SET_OPTION:
  2217. ***************
  2218. *** 909,920 ****
  2219.   
  2220.        case SM_RECOLLECT:    /* recollect */
  2221.           if (gh) {
  2222. !         if ((gh->master_flag & M_IGNORE_GROUP) == 0)
  2223.               clean_group(gh);
  2224.           } else
  2225.           Loop_Groups_Header(gh)
  2226. !             if ((gh->master_flag & M_IGNORE_GROUP) == 0)
  2227.               clean_group(gh);
  2228.           break;
  2229.   
  2230.        case SM_SCAN_ONCE:    /* unconditional pass */
  2231. --- 963,976 ----
  2232.   
  2233.        case SM_RECOLLECT:    /* recollect */
  2234.           if (gh) {
  2235. !         if ((gh->master_flag & M_IGNORE_GROUP) == 0){
  2236.               clean_group(gh);
  2237. +         }
  2238.           } else
  2239.           Loop_Groups_Header(gh)
  2240. !             if ((gh->master_flag & M_IGNORE_GROUP) == 0){
  2241.               clean_group(gh);
  2242. +             }
  2243.           break;
  2244.   
  2245.        case SM_SCAN_ONCE:    /* unconditional pass */
  2246. diff -c +recursive +new-file nn-6.4.16/menu.c ann/menu.c
  2247. *** nn-6.4.16/menu.c    Fri Oct 12 22:44:00 1984
  2248. --- ann/menu.c    Mon Mar 24 19:12:26 1985
  2249. ***************
  2250. *** 82,87 ****
  2251. --- 82,90 ----
  2252.       int mi_total;    /* total number of articles with this subject */
  2253.       int mi_unread;    /* no of unread articles with this subject */
  2254.       int mi_selected;    /* no of selected articles with this subject */
  2255. + #ifdef PATCH18
  2256. +     int mi_left;    /* no of articles marked for later viewing */
  2257. + #endif /* PATCH18 */
  2258.       int mi_art_id;    /* article id (for mark()) */
  2259.   } menu_info[INTERVAL1+INTERVAL2];
  2260.   
  2261. ***************
  2262. *** 138,146 ****
  2263. --- 141,151 ----
  2264.       if (ah->flag & A_ROOT_ART)
  2265.       return root;
  2266.   
  2267. + #ifndef PATCH18
  2268.       if (ah->flag & A_CLOSED)    /* only root article is shown on menu */
  2269.       return firsta + menu_info[ah->menu_line].mi_cura;
  2270.   
  2271. + #endif /* PATCH18 */
  2272.       while (root > 0) {
  2273.       if (articles[root]->flag & A_ROOT_ART) break;
  2274.       root--;
  2275. ***************
  2276. *** 172,187 ****
  2277. --- 177,203 ----
  2278.   {
  2279.       register struct menu_info *mi;
  2280.       register article_number n;
  2281. + #ifndef PATCH18
  2282.       int total, unread, selected, invisible;
  2283. + #else
  2284. +     int total, unread, selected, left, invisible;
  2285. + #endif /* PATCH18 */
  2286.       
  2287.       if (!(articles[art]->flag & A_CLOSED)) return art + 1;
  2288.       
  2289. + #ifndef PATCH18
  2290.       total = unread = selected = 0;
  2291. + #else
  2292. +     total = unread = selected = left = 0;
  2293. + #endif /* PATCH18 */
  2294.       n = art = root_article(art);
  2295.   
  2296.       while (n < n_articles) {
  2297.       if (articles[n]->attr == 0) unread++;
  2298.       else if (articles[n]->attr & A_SELECT) selected++; 
  2299. + #ifdef PATCH18
  2300. +     else if (articles[n]->attr == A_LEAVE_NEXT) left++;
  2301. + #endif /* PATCH18 */
  2302.       total++;
  2303.       if (++n == n_articles) break;
  2304.       if (articles[n]->flag & A_ROOT_ART) break;
  2305. ***************
  2306. *** 192,197 ****
  2307. --- 208,216 ----
  2308.       mi->mi_total = total;
  2309.       mi->mi_unread = unread;
  2310.       mi->mi_selected = selected;
  2311. + #ifdef PATCH18
  2312. +     mi->mi_left = left;
  2313. + #endif /* PATCH18 */
  2314.       return n;
  2315.   }
  2316.   
  2317. ***************
  2318. *** 206,215 ****
  2319. --- 225,244 ----
  2320.   register struct menu_info *mi;
  2321.   char *cbuf;
  2322.   {
  2323. + #ifndef PATCH18
  2324.       char sel[10], unr[10];
  2325. + #else
  2326. +     char lft[10], sel[10], unr[10];
  2327. + #endif /* PATCH18 */
  2328.       attr_type cattr;
  2329.       
  2330. + #ifndef PATCH18
  2331.       if (mi->mi_unread == 0)
  2332. + #else
  2333. +     if (mi->mi_total == mi->mi_left)
  2334. +     cattr = A_LEAVE_NEXT;
  2335. +     else if (mi->mi_unread == 0)
  2336. + #endif /* PATCH18 */
  2337.       cattr = A_READ;
  2338.       else if (mi->mi_total == mi->mi_selected)
  2339.       cattr = A_SELECT;
  2340. ***************
  2341. *** 220,231 ****
  2342. --- 249,270 ----
  2343.       else
  2344.       cattr = 0;
  2345.   
  2346. + #ifndef PATCH18
  2347.       sel[0] = unr[0] = NUL;
  2348. + #else
  2349. +     lft[0] = sel[0] = unr[0] = NUL;
  2350. +     if (mi->mi_left && mi->mi_left < mi->mi_unread)
  2351. +     sprintf(lft, "%d,", mi->mi_left);
  2352. + #endif /* PATCH18 */
  2353.       if (mi->mi_selected && mi->mi_selected < mi->mi_unread)
  2354.       sprintf(sel, "%d/", mi->mi_selected);
  2355.       if (mi->mi_unread && mi->mi_unread < mi->mi_total)
  2356.       sprintf(unr, "%d:", mi->mi_unread);
  2357. + #ifndef PATCH18
  2358.       sprintf(cbuf, "%s%s%d", sel, unr, mi->mi_total);
  2359. + #else
  2360. +     sprintf(cbuf, "%s%s%s%d", lft, sel, unr, mi->mi_total);
  2361. + #endif /* PATCH18 */
  2362.   
  2363.       return cattr;
  2364.   }
  2365. ***************
  2366. *** 268,273 ****
  2367. --- 307,315 ----
  2368.       thread_counters(firsta + cura);
  2369.       if (old.mi_total == mi->mi_total &&
  2370.           old.mi_selected == mi->mi_selected &&
  2371. + #ifdef PATCH18
  2372. +         old.mi_left == mi->mi_left &&
  2373. + #endif /* PATCH18 */
  2374.           old.mi_unread == mi->mi_unread) return;
  2375.   
  2376.       cattr = closed_attr(mi, cbuf);
  2377. ***************
  2378. *** 399,406 ****
  2379. --- 441,452 ----
  2380.       else {
  2381.           if (collapse_subject > 0)
  2382.           so_printf("%-.*s", collapse_subject, ah->subject);
  2383. + #ifndef PATCH17
  2384.           lsubj -= 2 + collapse_subject;
  2385.           so_printf("<>%s", ah->subject + ah->subj_length - lsubj);
  2386. + #else
  2387. +         so_printf("<>%s", ah->subject + ah->subj_length - lsubj + collapse_subject + 2);
  2388. + #endif /* PATCH17 */
  2389.       }
  2390.       }
  2391.   
  2392. ***************
  2393. *** 408,414 ****
  2394. --- 454,465 ----
  2395.       so_printf(ah->lines >= 0 ? " +%d" : " +?", ah->lines);
  2396.   
  2397.       so_end();
  2398. + #ifndef PATCH17
  2399.       if (ah->flag & A_CLOSED) clrline_noflush();
  2400. + #else
  2401. +     if ((ah->flag & A_CLOSED) && lsubj > ah->subj_length)
  2402. +         clrline_noflush();
  2403. + #endif /* PATCH17 */
  2404.   
  2405.    out:
  2406.       ah->disp_attr = last_attr;
  2407. ***************
  2408. *** 455,461 ****
  2409. --- 506,516 ----
  2410.   {
  2411.       register article_number i;
  2412.       register article_header *ah, **ahp;
  2413. + #ifndef PATCH17
  2414.       int count = 0, o_cura;
  2415. + #else
  2416. +     int count = 0, o_cura, should_mark;
  2417. + #endif /* PATCH17 */
  2418.       extern int kill_file_loaded;
  2419.   
  2420.       if (mode == 1 && re == NULL) 
  2421. ***************
  2422. *** 462,474 ****
  2423. --- 517,548 ----
  2424.       if (!kill_file_loaded && !init_kill()) return 0;
  2425.   
  2426.       o_cura = cura;
  2427. + #ifndef PATCH17
  2428.       cura = -1;
  2429. + #else
  2430. +     should_mark = 0;
  2431. + #endif /* PATCH17 */
  2432.   
  2433. + #ifdef PATCH17
  2434. +     /*
  2435. +      * note: this code assumes that a visible article will be found
  2436. +      * before anything is marked
  2437. +      */
  2438. + #endif
  2439.       for (i = 0, ahp = articles; i < n_articles; i++, ahp++) {
  2440.       ah = *ahp;
  2441. + #ifndef PATCH17
  2442.       if (cura >= 0 && (ah->flag & A_ROOT_ART)) {
  2443.           mark();
  2444.           cura = -1;
  2445. + #else
  2446. +     if (IS_VISIBLE(ah)) {
  2447. +         if (should_mark) {
  2448. +         mark();
  2449. +         should_mark = 0;
  2450. +         }
  2451. +         cura = i - firsta;
  2452. + #endif /* PATCH17 */
  2453.       }
  2454.       if (re != NULL) {
  2455.           if (!regexec_cf(re, select_on_sender ? ah->sender : ah->subject)) continue;
  2456. ***************
  2457. *** 478,483 ****
  2458. --- 552,558 ----
  2459.       count++;
  2460.       if (ah->attr & A_SELECT) continue;
  2461.       ah->attr = A_SELECT;
  2462. + #ifndef PATCH17
  2463.       if (firsta <= i && i <= (firsta+numa)) {
  2464.           cura = i - firsta;
  2465.           if ((ah->flag & A_CLOSED) == 0) {
  2466. ***************
  2467. *** 485,493 ****
  2468. --- 560,576 ----
  2469.           cura = -1;
  2470.           }
  2471.       }
  2472. + #else
  2473. +     if (firsta <= i && i <= (firsta+numa))
  2474. +         should_mark = 1;
  2475. + #endif /* PATCH17 */
  2476.       }
  2477.   
  2478. + #ifndef PATCH17
  2479.       if (cura >= 0) mark();
  2480. + #else
  2481. +     if (should_mark) mark();
  2482. + #endif /* PATCH17 */
  2483.   
  2484.       if (count)
  2485.       msg("Selected %d article%s", count, plural((long)count));
  2486. ***************
  2487. *** 617,624 ****
  2488. --- 700,723 ----
  2489.   
  2490.            case MC_MENU:
  2491.           ah->attr = o_attr;
  2492. + #ifndef PATCH18
  2493.           if (nexta - firsta < n_articles)
  2494.               if ((firsta = cur - 5) < 0) firsta = 0;
  2495. + #else
  2496. +         if (nexta - firsta < n_articles) {
  2497. +             /* Keep a little article context by making the */
  2498. +             /* current article go on menu line 6 if possible */
  2499. +             if (IS_VISIBLE(articles[cur]))
  2500. +                 firsta = cur;
  2501. +             else
  2502. +                 firsta = root_article(cur);
  2503. +             for (next = 0; firsta > 0 && next < 5; next++) {
  2504. +                 firsta--;
  2505. +                 if (!IS_VISIBLE(articles[firsta]))
  2506. +                     firsta = root_article(firsta);
  2507. +             }
  2508. +         }
  2509. + #endif /* PATCH18 */
  2510.           next_cura = cur - firsta;
  2511.   
  2512.           return MC_MENU;
  2513. ***************
  2514. *** 725,731 ****
  2515. --- 824,834 ----
  2516.       article_id = map & ~K_ARTICLE_ID;
  2517.       map = K_ARTICLE_ID;
  2518.   
  2519. + #ifndef PATCH17
  2520.       if (article_id < 0 || article_id > menu_articles) {
  2521. + #else
  2522. +     if (article_id < 0 || article_id >= menu_articles) {
  2523. + #endif /* PATCH17 */
  2524.           ding();
  2525.           goto loop;
  2526.       }
  2527. ***************
  2528. *** 817,824 ****
  2529. --- 920,937 ----
  2530.   attr_type old, new;
  2531.   int update;
  2532.   {
  2533. + #ifndef PATCH18
  2534.       return repl_attr(root_article(firsta+cura), next_root_article(firsta+cura),
  2535.                old, new, update);
  2536. + #else
  2537. +     int    f, l;
  2538. +     f = root_article(firsta+cura);
  2539. +     l = next_root_article(firsta+cura);
  2540. +     if (old == A_SELECT)
  2541. +     (void) repl_attr(f, l, A_AUTO_SELECT, A_SELECT, update);
  2542. +     return repl_attr(f, l, old, new, update);
  2543. + #endif /* PATCH18 */
  2544.   }
  2545.   
  2546.   static repl_attr_all(old, new, update)
  2547. ***************
  2548. *** 1639,1644 ****
  2549. --- 1752,1760 ----
  2550.        }
  2551.        cura = article_id;
  2552.        next_cura = next_root_article(firsta + cura) - firsta;
  2553. + #ifdef PATCH17
  2554. +      if (next_cura < 0 || next_cura > numa) next_cura = 0;
  2555. + #endif /* PATCH17 */
  2556.        if (cura >= 0) goto partial_redraw_nc;
  2557.        articles[cura + firsta]->menu_line = articles[firsta]->menu_line;
  2558.        firsta += cura;
  2559. diff -c +recursive +new-file nn-6.4.16/more.c ann/more.c
  2560. *** nn-6.4.16/more.c    Fri Oct 12 22:44:00 1984
  2561. --- ann/more.c    Thu Mar 27 18:45:45 1985
  2562. ***************
  2563. *** 21,27 ****
  2564. --- 21,35 ----
  2565.   export char *header_lines = NULL;
  2566.   export int  min_pv_window = 7;
  2567.   export int  wrap_headers = 6;
  2568. + /* AMIGA is 8 bit, so set data_bits to 8 as default */
  2569. + #ifndef AMIGA
  2570.   export int  data_bits = 7;
  2571. + #else
  2572. + export int  data_bits = 8;
  2573. + #endif
  2574.   export int  scroll_clear_page = 1;
  2575.   export int  expired_msg_delay = 1;
  2576.   export char *trusted_escapes = NULL;
  2577. diff -c +recursive +new-file nn-6.4.16/newsrc.c ann/newsrc.c
  2578. *** nn-6.4.16/newsrc.c    Fri Oct 12 22:44:00 1984
  2579. --- ann/newsrc.c    Thu Mar 27 18:13:29 1985
  2580. ***************
  2581. *** 10,15 ****
  2582. --- 10,19 ----
  2583.   #include "term.h"
  2584.   #include "articles.h"
  2585.   
  2586. + #ifdef    AMIGA
  2587. + extern    FILE    *debugfh;
  2588. + #endif
  2589.   #ifdef sel
  2590.   /* Remove Gould SELbus software name collision */
  2591.   #undef sel
  2592. ***************
  2593. *** 156,162 ****
  2594. --- 160,177 ----
  2595.       if (dump_file(newsrc_file, DM_NEWSRC)) {
  2596.       extern char *tmp_directory;
  2597.       char temp[FILENAME];
  2598. + #ifdef    AMIGA
  2599. +     if(tmp_directory[strlen(tmp_directory)-1]==':'){
  2600. +         sprintf(temp, "%snewsrc-%d", tmp_directory, process_id);
  2601. +     }
  2602. +     else{
  2603. +         sprintf(temp, "%s/newsrc-%d", tmp_directory, process_id);
  2604. +     }
  2605. + #else
  2606.       sprintf(temp, "%s/newsrc-%d", tmp_directory, process_id);
  2607. + #endif
  2608.       if (dump_file(temp, DM_NEWSRC))
  2609.           user_error("Cannot update %s -- restore %s file!!!",
  2610.                  newsrc_file, bak_suffix);
  2611. ***************
  2612. *** 1256,1262 ****
  2613.       Loop_Groups_Sequence(gh) {
  2614.       gh->unread_count = 0;
  2615.   
  2616. !     if (gh->master_flag & M_NO_DIRECTORY) continue;
  2617.   
  2618.       if (gh->last_db_article > gh->last_article) {
  2619.           n = unread_articles;
  2620. --- 1271,1279 ----
  2621.       Loop_Groups_Sequence(gh) {
  2622.       gh->unread_count = 0;
  2623.   
  2624. !     if (gh->master_flag & M_NO_DIRECTORY){
  2625. !          continue;
  2626. !     }
  2627.   
  2628.       if (gh->last_db_article > gh->last_article) {
  2629.           n = unread_articles;
  2630. diff -c +recursive +new-file nn-6.4.16/nn.c ann/nn.c
  2631. *** nn-6.4.16/nn.c    Fri Oct 12 22:44:00 1984
  2632. --- ann/nn.c    Thu Mar 27 18:14:23 1985
  2633. ***************
  2634. *** 4,9 ****
  2635. --- 4,13 ----
  2636.    *    The nn user interface main program
  2637.    */
  2638.   
  2639. + /*
  2640. +     modified to work with the Amiga by Alexander Rawass
  2641. + */
  2642.   #include "config.h"
  2643.   #include "menu.h"
  2644.   #include "term.h"
  2645. ***************
  2646. *** 15,20 ****
  2647. --- 19,29 ----
  2648.   #include <malloc.h>
  2649.   #endif
  2650.   
  2651. + #ifdef    AMIGA
  2652. + FILE    *debugfh;
  2653. + extern    unsigned    long    _Heapsize;
  2654. + #endif
  2655.   import char *bin_directory;
  2656.   
  2657.   import int
  2658. ***************
  2659. *** 679,684 ****
  2660. --- 688,699 ----
  2661.       extern long initial_memory_break;
  2662.       extern char *sbrk();
  2663.   
  2664. + #ifdef AMIGA
  2665. +     _Heapsize=150*1024L;
  2666. +     debugfh=fopen("*","w");
  2667. + #endif
  2668.       initial_memory_break = (long)sbrk(0);
  2669.   
  2670.   #ifdef USE_MALLOC_H
  2671. ***************
  2672. *** 695,700 ****
  2673. --- 710,735 ----
  2674.   
  2675.       pname = program_name(argv);
  2676.   
  2677. + #ifdef    AMIGA
  2678. + {
  2679. + int    i,be;
  2680. +     be=-1;
  2681. +     for(i=0;i<argc;i++){
  2682. +         if(strcmp(argv[i],"-be")==0){
  2683. +             pname=argv[i+1];
  2684. +             be=i;
  2685. +         }
  2686. +     }
  2687. +     
  2688. +     if(be!=-1){
  2689. +         for(i=be;i<argc-2;i++){
  2690. +             argv[i]=argv[i+2];
  2691. +         }
  2692. +     }
  2693. + }
  2694. + #endif    
  2695.       if (strcmp(pname, "nnadmin") == 0) {
  2696.       who_am_i = I_AM_ADMIN;
  2697.       } else
  2698. ***************
  2699. *** 984,990 ****
  2700.           prompt_line = 2;
  2701.           cmd = goto_group(K_GOTO_GROUP, (article_header *)NULL, setup_access());
  2702.           
  2703. !         if (cmd == ME_NO_REDRAW) sleep(2);
  2704.           } while (repeat_group_query && cmd != ME_QUIT && cmd != ME_NO_REDRAW);
  2705.           clrdisp();
  2706.           unset_raw();
  2707. --- 1019,1027 ----
  2708.           prompt_line = 2;
  2709.           cmd = goto_group(K_GOTO_GROUP, (article_header *)NULL, setup_access());
  2710.           
  2711. !         if (cmd == ME_NO_REDRAW){
  2712. !             sleep(2);
  2713. !         }
  2714.           } while (repeat_group_query && cmd != ME_QUIT && cmd != ME_NO_REDRAW);
  2715.           clrdisp();
  2716.           unset_raw();
  2717. ***************
  2718. *** 1025,1031 ****
  2719.       do_grep(argv+1);
  2720.       break;
  2721.       }
  2722.       nn_exit(0);
  2723.       /*NOTREACHED*/
  2724.   }
  2725. --- 1062,1067 ----
  2726. diff -c +recursive +new-file nn-6.4.16/nnmail.c ann/nnmail.c
  2727. *** nn-6.4.16/nnmail.c    Fri Oct 12 22:44:00 1984
  2728. --- ann/nnmail.c    Fri Mar 28 09:54:28 1985
  2729. ***************
  2730. *** 9,14 ****
  2731. --- 9,18 ----
  2732.   
  2733.   #include "options.h"
  2734.   
  2735. + #ifdef    AMIGA
  2736. + FILE    *debugfh;
  2737. + #endif
  2738.   char * MAILER = MAILX;
  2739.   static int print_vers, test_mode;
  2740.   
  2741. ***************
  2742. *** 30,35 ****
  2743. --- 34,43 ----
  2744.       char route[512];
  2745.       char *getenv(), *envmail;
  2746.       extern char **environ;
  2747. + #ifdef    AMIGA
  2748. +     debugfh=fopen("*","w");
  2749. + #endif
  2750.   
  2751.       if (envmail = getenv("NNMAILER"))
  2752.       MAILER = envmail;
  2753. diff -c +recursive +new-file nn-6.4.16/patchlevel.h ann/patchlevel.h
  2754. *** nn-6.4.16/patchlevel.h    Fri Oct 12 22:44:00 1984
  2755. --- ann/patchlevel.h    Mon Mar 24 18:29:17 1985
  2756. ***************
  2757. *** 27,33 ****
  2758. --- 27,43 ----
  2759.    *    1991-03-22: Patch #14 (6.4.14) - MEDIUM
  2760.    *    1991-04-02: Patch #15 (6.4.15) - LOW
  2761.    *    1991-04-18: Patch #16 (6.4.16) - HIGH
  2762. + #ifdef PATCH18
  2763. +  *
  2764. +  *    (Kim lost interest/dissapeared)
  2765. +  *
  2766. +  *    1991-11-19: Patch #17 (6.4.17) - MEDIUM
  2767. +  *    1991-12-01: Patch #18 (6.4.18) - MEDIUM
  2768.    */
  2769.   
  2770. + #ifndef PATCH18
  2771.   #define PATCHLEVEL 16
  2772. + #else
  2773. + #define PATCHLEVEL 18
  2774. + #endif /* PATCH18 */
  2775.   
  2776. diff -c +recursive +new-file nn-6.4.16/proto.c ann/proto.c
  2777. *** nn-6.4.16/proto.c    Fri Oct 12 22:44:00 1984
  2778. --- ann/proto.c    Fri Mar 28 09:55:14 1985
  2779. ***************
  2780. *** 10,15 ****
  2781. --- 10,19 ----
  2782.   #include <pwd.h>
  2783.   #include "proto.h"
  2784.   
  2785. + #ifdef    AMIGA
  2786. + extern    FILE    *debugfh;
  2787. + #endif
  2788.   #ifndef ACCOUNTING
  2789.   #ifdef AUTHORIZE
  2790.   #define ACCOUNTING
  2791. ***************
  2792. *** 224,229 ****
  2793. --- 228,234 ----
  2794.   long arg;
  2795.   {
  2796.       FILE *gate;
  2797.   
  2798.       gate = open_gate_file(OPEN_APPEND);
  2799.   
  2800. diff -c +recursive +new-file nn-6.4.16/readconfig.c ann/readconfig.c
  2801. *** nn-6.4.16/readconfig.c
  2802. --- ann/readconfig.c    Mon Mar 24 14:58:17 1985
  2803. ***************
  2804. *** 0 ****
  2805. --- 1,99 ----
  2806. + /*
  2807. +     reads the config file of your UUCP installation
  2808. +     
  2809. +     by Alexander Rawass, a_rawass@informatik.uni-kl.de
  2810. + */
  2811. + #include <exec/types.h>
  2812. + #include <stdio.h>
  2813. + #include "readconfig.h"
  2814. + #define    LMAX    200
  2815. + #define    CONFIGLINE(x)    (!(strncmp(x,lbuf,strlen(x))))
  2816. + VOID    stripM(buf)
  2817. + STRPTR    buf;
  2818. + {
  2819. +     int    i;
  2820. +     for(i=0;buf[i]!='\n' && buf[i]!=0;i++){
  2821. +         if(buf[i]==0x0d){
  2822. +             buf[i]=0;
  2823. +         }
  2824. +     }
  2825. +     buf[i]=0;
  2826. + }
  2827. + STRPTR    confname(buf)
  2828. + STRPTR    buf;
  2829. + {
  2830. + int    i;
  2831. +     for(i=0;buf[i]!=' ' && buf[i]!=0x09;i++)    ;    /* find first space */
  2832. +     
  2833. +     for(;buf[i]==' ' || buf[i]==0x09;i++)    ; /* find first non-space */
  2834. +     
  2835. +     return(buf+i);
  2836. + }
  2837. + BOOL    readconfig(name,conf)
  2838. + STRPTR    name;
  2839. + struct    uuconfig    *conf;
  2840. + {
  2841. + FILE    *fh;
  2842. + char    lbuf[LMAX];
  2843. +     fh=fopen(name,"r");
  2844. +     
  2845. +     if(fh==NULL){
  2846. +         return(FALSE);
  2847. +     }
  2848. +     
  2849. +     fgets(lbuf,LMAX,fh);
  2850. +     while(!feof(fh)){
  2851. +         stripM(lbuf);
  2852. +         if(CONFIGLINE("NodeName")){
  2853. +             strcpy(conf->NodeName,confname(lbuf));
  2854. +         }
  2855. +         else if(CONFIGLINE("UserName")){
  2856. +             strcpy(conf->UserName,confname(lbuf));
  2857. +         }
  2858. +         else if(CONFIGLINE("RealName")){
  2859. +             strcpy(conf->RealName,confname(lbuf));
  2860. +         }
  2861. +         else if(CONFIGLINE("Organization")){
  2862. +             strcpy(conf->Organization,confname(lbuf));
  2863. +         }
  2864. +         else if(CONFIGLINE("DomainName")){
  2865. +             strcpy(conf->DomainName,confname(lbuf));
  2866. +         }
  2867. +         else if(CONFIGLINE("Editor")){
  2868. +             strcpy(conf->Editor,confname(lbuf));
  2869. +         }
  2870. +         else if(CONFIGLINE("MailCommand")){
  2871. +             strcpy(conf->MailCommand,confname(lbuf));
  2872. +         }
  2873. +         else if(CONFIGLINE("NewsCommand")){
  2874. +             strcpy(conf->NewsCommand,confname(lbuf));
  2875. +         }
  2876. +         else if(CONFIGLINE("SaveFolder")){
  2877. +             strcpy(conf->SaveFolder,confname(lbuf));
  2878. +         }
  2879. +         else if(CONFIGLINE("NewsSignature")){
  2880. +             strcpy(conf->NewsSignature,confname(lbuf));
  2881. +         }
  2882. +         else if(CONFIGLINE("MailSignature")){
  2883. +             strcpy(conf->MailSignature,confname(lbuf));
  2884. +         }
  2885. +         fgets(lbuf,LMAX,fh);
  2886. +     }
  2887. +     
  2888. +     fclose(fh);
  2889. +     
  2890. +     return(TRUE);
  2891. + }
  2892. diff -c +recursive +new-file nn-6.4.16/readconfig.h ann/readconfig.h
  2893. *** nn-6.4.16/readconfig.h
  2894. --- ann/readconfig.h    Mon Mar 24 14:58:17 1985
  2895. ***************
  2896. *** 0 ****
  2897. --- 1,19 ----
  2898. + #define    UUMAX    200
  2899. + #define    LMAX    200
  2900. + struct    uuconfig {
  2901. +     /* for UUCP    */
  2902. +     char    NodeName[UUMAX];
  2903. +     char    UserName[UUMAX];
  2904. +     char    RealName[UUMAX];
  2905. +     char    Organization[UUMAX];
  2906. +     char    DomainName[UUMAX];
  2907. +     /* for Amiga-NN */
  2908. +     char    Editor[UUMAX];
  2909. +     char    MailCommand[UUMAX];
  2910. +     char    NewsCommand[UUMAX];
  2911. +     char    SaveFolder[UUMAX];
  2912. +     char    NewsSignature[UUMAX];
  2913. +     char    MailSignature[UUMAX];
  2914. + };
  2915. diff -c +recursive +new-file nn-6.4.16/save.c ann/save.c
  2916. *** nn-6.4.16/save.c    Fri Oct 12 22:44:00 1984
  2917. --- ann/save.c    Fri Mar 28 09:56:36 1985
  2918. ***************
  2919. *** 11,17 ****
  2920. --- 11,28 ----
  2921.   #include "keymap.h"
  2922.   #include "news.h"
  2923.   
  2924. + #ifdef    AMIGA
  2925. + extern    FILE    *debugfh;
  2926. + #endif
  2927. + /* to be compatible with ARN, AMIGA will use +$G */
  2928. + #ifdef    AMIGA
  2929. + export char *default_save_file = "+$G";
  2930. + #else
  2931.   export char *default_save_file = "+$F";
  2932. + #endif
  2933.   export char *folder_save_file = NULL;
  2934.   export int suggest_save_file = 1;
  2935.   export char *unshar_header_file = "Unshar.Headers";
  2936. ***************
  2937. *** 143,148 ****
  2938. --- 154,161 ----
  2939.           continue;
  2940.       }
  2941.       *slash = NUL;
  2942. +     
  2943.       if (mkdir(name, 0755)) {
  2944.           msg("Cannot make %s/", name);
  2945.           *slash = '/';
  2946. ***************
  2947. *** 218,223 ****
  2948. --- 231,237 ----
  2949.           }
  2950.   
  2951.           save_name = get_s(last_input, save_name, NONE, file_completion);
  2952.           if (save_name == NULL || *save_name == NUL) return NULL;
  2953.   
  2954.           if (save_name[1] == NUL && save_name[0] == '+')
  2955. ***************
  2956. *** 727,732 ****
  2957. --- 741,747 ----
  2958.       msg("Directory %s already exists", dir);
  2959.       return NULL;
  2960.       }
  2961.   
  2962.       if (mkdir(dir, 0755)) {
  2963.       msg("Cannot make %s", dir);
  2964. diff -c +recursive +new-file nn-6.4.16/sequence.c ann/sequence.c
  2965. *** nn-6.4.16/sequence.c    Fri Oct 12 22:44:00 1984
  2966. --- ann/sequence.c    Fri Mar 28 09:57:32 1985
  2967. ***************
  2968. *** 7,12 ****
  2969. --- 7,16 ----
  2970.   #include "config.h"
  2971.   #include "debug.h"
  2972.   
  2973. + #ifdef    AMIGA
  2974. + extern    FILE    *debugfh;
  2975. + #endif
  2976.   export group_header *group_sequence;
  2977.   export char *read_mail = NULL;
  2978.   export int also_subgroups = 1;
  2979. ***************
  2980. *** 94,101 ****
  2981.   
  2982.       gh->group_flag |= G_SEQUENCE;
  2983.   
  2984. !     if (gh->master_flag & M_NO_DIRECTORY)
  2985.       return 0;        /* for nntidy -s */
  2986.   
  2987.       switch (mode) {
  2988.        case SHOW_FIRST:
  2989. --- 98,106 ----
  2990.   
  2991.       gh->group_flag |= G_SEQUENCE;
  2992.   
  2993. !     if (gh->master_flag & M_NO_DIRECTORY){
  2994.       return 0;        /* for nntidy -s */
  2995. +     }
  2996.   
  2997.       switch (mode) {
  2998.        case SHOW_FIRST:
  2999. diff -c +recursive +new-file nn-6.4.16/simplenews.c ann/simplenews.c
  3000. *** nn-6.4.16/simplenews.c
  3001. --- ann/simplenews.c    Mon Mar 24 14:51:02 1985
  3002. ***************
  3003. *** 0 ****
  3004. --- 1,91 ----
  3005. + /*
  3006. +     Simplenews
  3007. +     by Alexander Rawass, a_rawass@informatik.uni-kl.de
  3008. + */
  3009. + #include <stdio.h>
  3010. + #include <exec/types.h>
  3011. + #include <time.h>
  3012. + #include "readconfig.h"
  3013. + #define    LMAX 200
  3014. + #define    LAST_SIMPLENEWS    "t:last.simplenews"
  3015. + time_t cur_time()
  3016. + {
  3017. +     time_t t;
  3018. +     time(&t);
  3019. +     return t;
  3020. + }
  3021. + int    main(argc,argv)
  3022. + int    argc;
  3023. + STRPTR    argv[];
  3024. + {
  3025. + FILE    *ifh;
  3026. + FILE    *ofh;
  3027. + FILE    *sfh;
  3028. + char    wname[100];
  3029. + char    combuf[100];
  3030. + char    buf[LMAX];
  3031. + time_t now;
  3032. + extern struct tm *gmtime();
  3033. + extern char *asctime();
  3034. + char *date;
  3035. + int    ok;
  3036. + struct    uuconfig    conf;
  3037. +     if(argc<2){
  3038. +         exit(42);
  3039. +     }
  3040. +     
  3041. +     if(readconfig("uulib:config",&conf)==FALSE
  3042. +         || readconfig("uulib:.nnrc",&conf)==FALSE){
  3043. +         exit(117);        
  3044. +     }
  3045. +     
  3046. +     ifh=fopen(argv[1],"r");
  3047. +     
  3048. +     sprintf(wname,"%s.simplenews",argv[1]);
  3049. +     ofh=fopen(wname,"w");
  3050. +     fprintf(ofh,"Path: %s!%s\n",conf.NodeName,conf.UserName);
  3051. +     fprintf(ofh,"From: %s@%s%s (%s)\n",conf.UserName,conf.NodeName,conf.DomainName,conf.RealName);
  3052. +     fprintf(ofh,"Distribution: world\n");
  3053. +     fprintf(ofh,"Organization: %s\n",conf.Organization);
  3054. +     now = cur_time();
  3055. +     date = asctime(gmtime(&now));
  3056. +     date[3] = date[7] = date[10] = date[19] = date[24] = 0;
  3057. +     fprintf(ofh, "Date: %s %s %s %s GMT\n", date+8, date+4, date+22, date+11);
  3058. +     fprintf(ofh, "Message-ID: <%s.%ld@%s%s>\n",conf.UserName,(long)now,conf.NodeName,conf.DomainName );
  3059. +     fgets(buf,LMAX,ifh);
  3060. +     while(!feof(ifh)){
  3061. +         fputs(buf,ofh);
  3062. +         fgets(buf,LMAX,ifh);
  3063. +     }
  3064. +     
  3065. +     fclose(ifh);
  3066. +     sfh=fopen(conf.NewsSignature,"r");
  3067. +     fgets(buf,LMAX,sfh);
  3068. +     while(!feof(sfh)){
  3069. +         fputs(buf,ofh);
  3070. +         fgets(buf,LMAX,sfh);
  3071. +     }
  3072. +     fclose(sfh);
  3073. +     
  3074. +     fclose(ofh);
  3075. +     sprintf(combuf,"relaynews <%s -i",wname);
  3076. +     ok=system(combuf);
  3077. +     
  3078. +     unlink(wname);
  3079. +     
  3080. +     exit(ok);
  3081. + }
  3082. diff -c +recursive +new-file nn-6.4.16/term.c ann/term.c
  3083. *** nn-6.4.16/term.c    Fri Oct 12 22:44:00 1984
  3084. --- ann/term.c    Wed Mar 05 10:05:30 1985
  3085. ***************
  3086. *** 112,123 ****
  3087. --- 112,129 ----
  3088.   extern char fake_keyb_siglist[];
  3089.   #endif
  3090.   
  3091. + #ifdef    AMIGA
  3092. + #undef    HAVE_TERMIO
  3093. + #endif
  3094.   #ifdef HAVE_TERMIO
  3095.   
  3096.   #define KEY_BURST 50    /* read bursts of 50 chars (or timeout after 100 ms) */
  3097.   
  3098. + #ifndef AMIGA
  3099.   #ifdef USE_TERMCAP
  3100.   #include <termio.h>
  3101. + #endif
  3102.   #endif
  3103.   
  3104.   #undef CBREAK
  3105. diff -c +recursive +new-file nn-6.4.16/update.h ann/update.h
  3106. *** nn-6.4.16/update.h    Wed Feb 06 06:37:00 1985
  3107. --- ann/update.h
  3108. ***************
  3109. *** 1 ****
  3110. - 5
  3111. --- 0 ----
  3112.