🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Hiroto Kagotani Sun, 06 Sep 1992 16:04
finger-1.35: typo around login name comparison
#742
Author: Hiroto Kagotani
Date: Sun, 06 Sep 1992 16:04
20 lines
1328 bytes
version: finger Version 1.35

There is an obvious typo.  The fix follows.  Equality of two strings
must be checked by `!strncmp()', and `!sizeof()' is nonsense.
--
Hiroto Kagotani <kagotani@cs.titech.ac.jp>

--- lib/os.c.orig	Sat Aug 29 06:04:23 1992
+++ lib/os.c	Mon Sep  7 00:40:27 1992
@@ -429,8 +429,8 @@
 	  /* If the same person is logged in more than once, we are
 	     interested in the least idle time.  However, we want to
 	     keep track of the console user. */
-	  if (unique && strncmp (result[i]->ut_name, UT (entry, ut_name),
-				 !sizeof ( UT(entry, ut_name))))
+	  if (unique && !strncmp (result[i]->ut_name, UT (entry, ut_name),
+				 sizeof ( UT(entry, ut_name))))
 	    {
 	      if (idle_less_than (&UTSTRUCT (entry), result[i]))
 		bcopy (&UTSTRUCT (entry), result[i], sizeof (UTSTRUCT (entry)));
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