From nobody  Fri Jan 10 10:54:31 1997
Received: (from nobody@localhost)
          by freefall.freebsd.org (8.8.4/8.8.4) id KAA25750;
          Fri, 10 Jan 1997 10:54:31 -0800 (PST)
Message-Id: <199701101854.KAA25750@freefall.freebsd.org>
Date: Fri, 10 Jan 1997 10:54:31 -0800 (PST)
From: scrutchfield@ifusion.com
To: freebsd-gnats-submit@freebsd.org
Subject: Typo in libc and libc_r functions results in undefined symbol at runtime.
X-Send-Pr-Version: www-1.0

>Number:         2440
>Category:       bin
>Synopsis:       Typo in libc and libc_r functions results in undefined symbol at runtime.
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    julian
>State:          closed
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jan 10 11:00:00 PST 1997
>Closed-Date:    Sat Mar 8 22:53:09 PST 1997
>Last-Modified:  Sat Mar  8 22:54:02 PST 1997
>Originator:     Steven M. Crutchfield
>Release:        2.2-BETA
>Organization:
IFusionCom
>Environment:
FreeBSD no_dobbs.ifusion.com 2.2-BETA_A FreeBSD 2.2-BETA_A #0: Tue Jan  7 16:05:22 EST 1997     root@no_dobbs.ifusion.com:/usr/src/sys/compile/PS2MOUSE  i386
>Description:
While linking an application that required the pthread version of libc,
I discovered a typo in libc.  The problem is a function named
"pthread_key_create" that was being called as "pthread_keycreate", which
could not be resolved at runtime.  Upon examining the source for libc,
I discovered that there were 3 instances where it was incorrectly named:

/usr/src/lib/libc/gen/ttyname.c - line 120
/usr/src/lib/libc/stdtime/localtime.c - lines 1105 and 1189

Changing these references to the correct function name fixed the problem.
>How-To-Repeat:
Do anything requiring the above functions to be linked in.
>Fix:
Changing these references from "pthread_keycreate" to "pthread_key_create"
fixed the problem.

/usr/src/lib/libc/gen/ttyname.c - line 120
/usr/src/lib/libc/stdtime/localtime.c - lines 1105 and 1189

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->analyzed 
State-Changed-By: mpp 
State-Changed-When: Mon Feb 17 09:13:02 PST 1997 
State-Changed-Why:  
This has been fixed in -current. on 2/5/97. 


Responsible-Changed-From-To: freebsd-bugs->joerg 
Responsible-Changed-By: mpp 
Responsible-Changed-When: Mon Feb 17 09:13:02 PST 1997 
Responsible-Changed-Why:  
Joerg, as RE you should see about YAMFC of the uthreads update 
in libc that Julian committed last week to fix this problem. 
in 2.2. 
Responsible-Changed-From-To: joerg->julian 
Responsible-Changed-By: joerg 
Responsible-Changed-When: Tue Feb 25 00:27:05 MET 1997 
Responsible-Changed-Why:  
I don't feel competent for the threaded libc. 
Either Julian's going to do this himself, or it won't happen in 2.2. 
I'm more likely to break things in this field than fixing them. 
State-Changed-From-To: analyzed->closed 
State-Changed-By: mpp 
State-Changed-When: Sat Mar 8 22:53:09 PST 1997 
State-Changed-Why:  
Fixed in -current.  There are no current plans to merge this into 2.2. 
>Unformatted:
