🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nn
1 messages
1 total messages Started by David Maltz Fri, 06 Aug 1993 23:42
patch to fix server load bug...
#4603
Author: David Maltz
Date: Fri, 06 Aug 1993 23:42
83 lines
3315 bytes
Our site has been having problems with the load on the news server
going above 6.  This wouldn't be a problem except that nntp daemons
have this cute habit of refusing any new connections when the load is
above 6.  This in itself is a fine way of reducing the load on the
server, but nn 6.4.16's behavior clashes against it.  If the server
load is above 6, nn will show the user a menu of available subjects,
let the user chose which articles to read, and then dump the user out
of nn with out saving the selections when it tries to connect to the
server.

The patchs below to nntp.c and more.c seem to fix this.  The new
behavior is to put a message on the screen that nn couldn't connect
to the server, and then put the user back into the article selection
mode.  If the user hits space again, another attempt to connect will
be made.  If the user quits out of nn, the selection should be saved
as usual.  As always, no guarantees, warantees, promise of fitness
for use, etc, etc, etc...

-Dave Maltz
maltz@parc.xerox.com
+1 415 812 4950
-Stnd Disclaimer:  I do not speak for the company.

- cut here for context diffs -

*** nntp.c	Fri Aug  6 13:58:53 1993
--- /import/misc/nn-6.4.16/nntp.c	Sun Jan 13 12:01:43 1991
***************
*** 416,431 ****
  	    can_post = 0;
  	    break;
  	default:
! 	    msg("Couldn't connect to server %s (server sez:%s)",
! 		nntp_server,line);
! 	    is_connected = 0;
! 	    fclose(nntp_out);
! 	    fclose(nntp_in);
! 	    user_delay(2);
! 	    return -1;
! /*	    user_error(line); -removed to get rid of nn's annoying habit of
! 	                      dumping the user out of the program whenever
! 			      the news server's loadav is > 6 -dam */
  	    /* NOTREACHED */
  	}
      }
--- 416,422 ----
  	    can_post = 0;
  	    break;
  	default:
! 	    user_error(line);
  	    /* NOTREACHED */
  	}
      }


*** more.c	Fri Aug  6 16:04:30 1993
--- /import/misc/nn-6.4.16/more.c	Wed Nov 13 15:55:57 1991
***************
*** 337,345 ****
      int open_modes, hdr_mode, o_mode;
      struct header_def *hdef;
      extern int alt_cmd_key, in_menu_mode, any_message;
- #ifdef NNTP
-     extern int nntp_failed;  /* from nntp.c -dam */
- #endif
  #ifdef RESIZING
      int entry_col = Columns;
  #endif
--- 337,342 ----
***************
*** 361,370 ****
      }
  
      art = open_news_article(ah, open_modes, ngheader, dgheader);
- 
- #ifdef NNTP    
-     if (nntp_failed) return MC_MENU; /* couldn't read the news... -dam*/
- #endif /* NNTP */
  
      if (art == NULL) {
  	if (expired_msg_delay >= 0) {
--- 358,363 ----
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads