Subject: Patch for disabling the Update function

From: Jos Vos <[email-masked]>
Date: Thu, 21 Oct 93 17:24:57 MET

Because I wanted to disable the Update function that (IMHO)
may confuse our users (and does not work here),
I've made the following patch to be able to disable it at
compile time (macro: DISABLE_UPDATE).

I'ld like to have it be included in future releases of Pine.

------CUT HERE------
*** pine/pine.c.org	Tue Oct 12 15:49:30 1993
--- pine/pine.c	Tue Oct 12 15:53:57 1993
***************
*** 663,669 ****
--- 663,673 ----
    {"   %s     ADDRESS BOOK       -  Update address book", 
              OPF10, 'A', ADDRESS_KEY},
    {"", UNUSED, UNUSED, UNUSED},
+ #ifndef DISABLE_UPDATE
    {"   %s     SETUP              -  Configure or update Pine", 
+ #else
+   {"   %s     SETUP              -  Configure Pine", 
+ #endif
              OPF9, 'S',SETUP_KEY},
    {"", UNUSED, UNUSED, UNUSED},
    {"   %s     QUIT               -  Exit the Pine program", 
***************
*** 1205,1211 ****
--- 1209,1217 ----
  char *setup_names[] =	{"Printer",
  			 "Newpassword",
  			 "Options",
+ #ifndef DISABLE_UPDATE
  			 "Update",
+ #endif
  			 "Exit",
  			  NULL};
  /*----------------------------------------------------------------------
***************
*** 1223,1232 ****
--- 1229,1246 ----
      HelpType  help;
  
      (void)strcpy(prompt,
+ #ifndef DISABLE_UPDATE
           "SETUP (Printer,Newpassword,Options,Update,[Exit]; type PNOU or E): ");
+ #else
+          "SETUP (Printer,Newpassword,Options,[Exit]; type PNO or E): ");
+ #endif
  
      help = h_mini_setup;
+ #ifndef DISABLE_UPDATE
      s = radio_buttons(prompt, ql, 0, "pnoue", setup_names, 'e', 'x', help, 0);
+ #else
+     s = radio_buttons(prompt, ql, 0, "pnoe", setup_names, 'e', 'x', help, 0);
+ #endif
      /* ^C */
      if(s == 'x') {
  	Writechar('\007', 0);
***************
*** 1255,1260 ****
--- 1269,1275 ----
   * much, we can always turn pine.cac into a multi-address name which
   * randomizes.
   */
+ #ifndef DISABLE_UPDATE
  #define UPDATE_FOLDER "*{pine.cac.washington.edu/anonymous}updates"
          /*----- UPDATE -----*/
        case 'u':
***************
*** 1262,1267 ****
--- 1277,1283 ----
          if(do_broach_folder(UPDATE_FOLDER, NULL) > 0)
            ps_global->next_screen = mail_index_screen;
  	break;
+ #endif
  
          /*----- SET OPTIONS -----*/
        case 'o':
------CUT HERE------

-- 
--    Jos Vos <[email-masked]>   (UUCP: ...!{uunet,mcsun,sun4nl}!nlbull!jos)
--    Bull Netherlands, Professional Services, Amsterdam, The Netherlands