[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [leafnode-list] 2.0b3 compile-time warnings



Matthias Andree wrote:

> I have done the following:
> * replaced all 'new' by 'n' (allows to compile leafnode with g++ which
>   allows for stricter type checking)
> * replaced all sscanf with only one argument to parse by a new get_long
>   function 
> * fixed all signedness issues
> * fixed some Makefile bugs (some rm -f's belonging into distclean were
>   in clean)
> * removed "TRUE" (bad style and error prone)
> * removed explicit comparisons against FALSE and TRUE (bad style)

Except the last two things (which is probably a consequence of me having
done my first programming in Pascal and therefore have slightly
different opinions of "style" :-), I have incorporated all (I hope I
didn't overlook anything) of Matthias' patches into 2.0b4 which is now
available from
	ftp://wpxx02.toxi.uni-wuerzburg.de/pub/leafnode-2.0b4.tar.gz
None of the major bugs has been fixed; i.e. if you had coredumps with
2.0b3 you will most likely have them with 2.0b4 as well. This is due
to me spending the weekend with my girlfriend instead of my computer :-)

I include the full ChangeLog here:

%cut here

applyfilter:
===========

291000: the char constant -\|/ is now declared "const". Patch by
	Matthias Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: made "n" unsigned long. Suggested by Matthias Andree
	<ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.

fetchnews:
=========

291000: main(): msgid declared as "static" which removes the obnoxious
	warning about it being affected by longjmp().
291000: doxover() and doxhdr(): converted a few "unsigned char *" into
	"char *". Suggested by Matthias Andree
	<ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: made global variable "windowsize" unsigned long. Suggested by
	Matthias Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: doxhdr: removed unnecessary parameter "groupname" from declaration.
	Suggested by Matthias Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.

libutil:
=======

291000: xoverutil: writexover(): new variable lineend to bring constant
	"\n" into header. Suggested by Matthias Andree
	<ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: miscutil: error logging in critmalloc()/critrealloc() is now
	done with long instead of int. Patch by Matthias Andree
	<ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: miscutil: did casting of malloc()/realloc() return values in
	critmalloc()/critrealloc(), respectively. Patch by Matthias
	Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: activutil: readactive(): return value of memchr() is now casted.
	Patch by Matthias Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: activutil: helpfindgroup() could return -1 and therefore should
	not be declared "unsigned". Patch by Matthias Andree
	<ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: xoverutil: return value of findxover() now long int instead of int.
	Suggested by Joerg Dietrich <joerg@xxxxxxxxxxxx>.
291000: xoverutil: parameter to findxover() now declared as unsigned long
	instead of int.
291000: filterutil: killfilter(): removed unnecessary parameter "artno".
	Suggested by Matthias Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: artutil: modified call of store() by removing all unnecessary
	parameters. Suggested by Matthias Andree
	<ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
271000: xoverutil: helpfindxover() would segfault under certain
	circumstances if the calculation of "new" yielded 0. Bug
	fixed by Joerg Dietrich <joerg@xxxxxxxxxxxx>.

nntpd:
=====

291000: global variable "cmd" declared "static". Suggested by Matthias
	Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: dolistgroup(): declared art as unsigned long instead of int.
	Suggested by Matthias Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: doxover(): declared art, a, b as unsigned long instead of int.
	Suggested by Matthias Andree <ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.
291000: doselectedheader(): declared a, b and c as unsigned long instead
	of int. Suggested by Matthias Andree
	<ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.

General:
=======

291000: renamed all variables called "new" to something else. This makes
	it possible to compile leafnode with g++ which does much stricter
	type-checking than gcc. Suggested by Matthias Andree
	<ma@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>.

%cut here

The reason for releasing 2.0b4 is that it gives us a common base to
build upon instead of patching signedness issues again in a couple
of weeks.

I will hopefully have a look into (some of) the coredumps next week.

--Cornelius.

-- 
/* Cornelius Krasel, U Wuerzburg, Dept. of Pharmacology, Versbacher Str. 9 */
/* D-97078 Wuerzburg, Germany   email: phak004@xxxxxxxxxxxxxxxxxxxxxx  SP4 */
/* "Science is the game we play with God to find out what His rules are."  */

-- 
leafnode-list@xxxxxxxxxxxxxxxxxxxxxxxxxxxx -- mailing list for leafnode
To unsubscribe, send mail with "unsubscribe" in the subject to the list