From mpp@mpp.minn.net  Mon Jan 22 05:53:03 1996
Received: from mpp.minn.net (root@mpp.Minn.Net [204.157.201.242])
          by freefall.freebsd.org (8.7.3/8.7.3) with ESMTP id FAA12254
          for <FreeBSD-gnats-submit@freebsd.org>; Mon, 22 Jan 1996 05:53:01 -0800 (PST)
Received: (from mpp@localhost) by mpp.minn.net (8.7.3/8.6.9) id HAA20973; Mon, 22 Jan 1996 07:53:00 -0600 (CST)
Message-Id: <199601221353.HAA20973@mpp.minn.net>
Date: Mon, 22 Jan 1996 07:53:00 -0600 (CST)
From: Mike Pritchard <mpp@minn.net>
Reply-To: mpp@mpp.minn.net
To: FreeBSD-gnats-submit@freebsd.org
Subject: Net user in password file causes malloc warning msgs
X-Send-Pr-Version: 3.2

>Number:         964
>Category:       bin
>Synopsis:       Net user in password file causes malloc warning msgs
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jan 22 06:00:01 PST 1996
>Closed-Date:    Mon Jan 29 12:16:42 PST 1996
>Last-Modified:  Mon Jan 29 12:17:52 PST 1996
>Originator:     Mike Pritchard
>Release:        FreeBSD 2.2-CURRENT i386
>Organization:
Mike Pritchard
>Environment:

FreeBSD 2.2-CURRENT as of about a week ago

>Description:

While running a test case from a PR, I added a NIS type user to
the end of my password file (+mpptest:*:0:0:...).  After that,
every program that calls the getpw* routines issues the following
malloc messages:

Malloc warning: free(): junk pointer (too low)
  - or -
Malloc warning: free(): junk pointer (too high)

It also scared the hell out of me when vipw issued the same
warning when I went in to remove that user from my password file.

NOTE: I am not really running any of the NIS stuff, I was
just attempting to verify a PR, so that may be why things
are getting screw up.  Either way there is something wrong
that needs to be fixed.

>How-To-Repeat:

Add a line like:

+mpptest:*:0:0:...

to the end of your password file.

>Fix:
	
Haven't looked. I figured I'd let someone who knows something
about this code take a shot at it first.
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: mpp 
State-Changed-When: Mon Jan 29 12:16:42 PST 1996 
State-Changed-Why:  
Fixed in rev 1.31 of libc/gen/getpwent.c. 
>Unformatted:
