🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nn
1 messages
1 total messages Started by Romain Kang Sun, 29 Jan 1995 22:53
fixes for my NN+NOV speedups
#7051
Author: Romain Kang
Date: Sun, 29 Jan 1995 22:53
63 lines
2953 bytes
For folks attempting to run my patch for 6.5.0.b3, there are a couple
of problems that have been brought to my attention and fixed.  There
are two fixes that follow; these should be made against code that has
already had my patches applied.

First, db.c has strkeep() patched to ensure correct alignment of the
objects it returns -- on DEC Alpha platforms, sizeof(int) != sizeof(pointer),
and I blush that I did not realize this after all the VAX/PDP-11 code I
had to wrangle when I was a student.  The quick and dirty fix here is
to assure the size requested from the pool is a pointer size multiple.
When I have time to think about it, I have to fix the code so that
pmalloc() always returns pointer-aligned memory, and get rid of the
str[0] construct, since some C compilers don't like it, and it's kind
of grotty anyhow.

Second, while running with access to the .overview files, groups
with just one unread article in them would get entered, but NN would
miss the NOV data and merrily jump to the next group.  This was just
a classic fencepost error.

My deep gratitude goes to these folks for their time and effort to help
me find and fix the bugs that have popped up so far:
	J. Porter Clark <Porter.Clark@msfc.nasa.gov>
	Bill Tutt <rassilon@cs.simpson.edu>
	Toivo Pedaste <toivo@ucs.uwa.edu.au>

Romain

*** db.c.5	Thu Jan 12 09:39:13 1995
--- db.c	Fri Jan 27 08:02:34 1995
***************
*** 1947,1951
      }
      else {
! 	size = (hdr + strlen(s) + sizeof(int)) & ~(sizeof(int) - 1);
  	ret = pmalloc(size, poolid);
      }

--- 1947,1951 -----
      }
      else {
! 	size = (hdr + strlen(s) + sizeof(char *)) & ~(sizeof(char *) - 1);
  	ret = pmalloc(size, poolid);
      }
*** libnov.c.1	Fri Dec 30 16:43:02 1994
--- libnov.c	Sun Jan 29 14:26:40 1995
***************
*** 159,163
  	    break;
  
! 	if ((line = fgetstr(fp)) != NULL && atol(line) > artnum)
  	    upper = middle;
  	else if (lower == middle)

--- 159,163 -----
  	    break;
  
! 	if ((line = fgetstr(fp)) != NULL && atol(line) >= artnum)
  	    upper = middle;
  	else if (lower == middle)
--
Romain Kang					Pyramid Technology Corp.
romain@pyramid.com				San Jose, California, USA
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