Module Name: src Committed By: joerg Date: Wed Dec 8 02:06:38 UTC 2010
Modified Files: src/lib/libc/rpc: clnt_dg.c clnt_simple.c clnt_vc.c getnetconfig.c mt_misc.c rpc_generic.c rpc_soc.c Log Message: Use __isthreaded from reentrant.h and don't redeclare it. To generate a diff of this commit: cvs rdiff -u -r1.23 -r1.24 src/lib/libc/rpc/clnt_dg.c \ src/lib/libc/rpc/rpc_generic.c cvs rdiff -u -r1.29 -r1.30 src/lib/libc/rpc/clnt_simple.c cvs rdiff -u -r1.16 -r1.17 src/lib/libc/rpc/clnt_vc.c cvs rdiff -u -r1.17 -r1.18 src/lib/libc/rpc/getnetconfig.c cvs rdiff -u -r1.7 -r1.8 src/lib/libc/rpc/mt_misc.c cvs rdiff -u -r1.12 -r1.13 src/lib/libc/rpc/rpc_soc.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/lib/libc/rpc/clnt_dg.c diff -u src/lib/libc/rpc/clnt_dg.c:1.23 src/lib/libc/rpc/clnt_dg.c:1.24 --- src/lib/libc/rpc/clnt_dg.c:1.23 Thu Feb 12 04:33:20 2009 +++ src/lib/libc/rpc/clnt_dg.c Wed Dec 8 02:06:38 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: clnt_dg.c,v 1.23 2009/02/12 04:33:20 lukem Exp $ */ +/* $NetBSD: clnt_dg.c,v 1.24 2010/12/08 02:06:38 joerg Exp $ */ /* * Sun RPC is a product of Sun Microsystems, Inc. and is provided for @@ -39,7 +39,7 @@ #if 0 static char sccsid[] = "@(#)clnt_dg.c 1.19 89/03/16 Copyr 1988 Sun Micro"; #else -__RCSID("$NetBSD: clnt_dg.c,v 1.23 2009/02/12 04:33:20 lukem Exp $"); +__RCSID("$NetBSD: clnt_dg.c,v 1.24 2010/12/08 02:06:38 joerg Exp $"); #endif #endif @@ -99,7 +99,6 @@ */ static int *dg_fd_locks; #ifdef _REENTRANT -extern int __isthreaded; #define __rpc_lock_value __isthreaded; extern mutex_t clnt_fd_lock; static cond_t *dg_cv; Index: src/lib/libc/rpc/rpc_generic.c diff -u src/lib/libc/rpc/rpc_generic.c:1.23 src/lib/libc/rpc/rpc_generic.c:1.24 --- src/lib/libc/rpc/rpc_generic.c:1.23 Fri Apr 25 17:44:44 2008 +++ src/lib/libc/rpc/rpc_generic.c Wed Dec 8 02:06:38 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: rpc_generic.c,v 1.23 2008/04/25 17:44:44 christos Exp $ */ +/* $NetBSD: rpc_generic.c,v 1.24 2010/12/08 02:06:38 joerg Exp $ */ /* * Sun RPC is a product of Sun Microsystems, Inc. and is provided for @@ -41,7 +41,7 @@ #include <sys/cdefs.h> #if defined(LIBC_SCCS) && !defined(lint) -__RCSID("$NetBSD: rpc_generic.c,v 1.23 2008/04/25 17:44:44 christos Exp $"); +__RCSID("$NetBSD: rpc_generic.c,v 1.24 2010/12/08 02:06:38 joerg Exp $"); #endif #include "namespace.h" @@ -258,8 +258,6 @@ static char *netid_udp_main; struct netconfig *dummy; #ifdef _REENTRANT - extern int __isthreaded; - if (__isthreaded == 0) { netid_udp = netid_udp_main; netid_tcp = netid_tcp_main; Index: src/lib/libc/rpc/clnt_simple.c diff -u src/lib/libc/rpc/clnt_simple.c:1.29 src/lib/libc/rpc/clnt_simple.c:1.30 --- src/lib/libc/rpc/clnt_simple.c:1.29 Fri Nov 3 23:16:12 2006 +++ src/lib/libc/rpc/clnt_simple.c Wed Dec 8 02:06:38 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: clnt_simple.c,v 1.29 2006/11/03 23:16:12 christos Exp $ */ +/* $NetBSD: clnt_simple.c,v 1.30 2010/12/08 02:06:38 joerg Exp $ */ /* * Sun RPC is a product of Sun Microsystems, Inc. and is provided for @@ -39,7 +39,7 @@ #if 0 static char sccsid[] = "@(#)clnt_simple.c 1.49 89/01/31 Copyr 1984 Sun Micro"; #else -__RCSID("$NetBSD: clnt_simple.c,v 1.29 2006/11/03 23:16:12 christos Exp $"); +__RCSID("$NetBSD: clnt_simple.c,v 1.30 2010/12/08 02:06:38 joerg Exp $"); #endif #endif @@ -131,7 +131,6 @@ struct rpc_call_private *rcp = (struct rpc_call_private *) 0; enum clnt_stat clnt_stat; struct timeval timeout, tottimeout; - extern int __isthreaded; _DIAGASSERT(host != NULL); /* XXX: in may be NULL ??? */ Index: src/lib/libc/rpc/clnt_vc.c diff -u src/lib/libc/rpc/clnt_vc.c:1.16 src/lib/libc/rpc/clnt_vc.c:1.17 --- src/lib/libc/rpc/clnt_vc.c:1.16 Thu Feb 12 16:24:59 2009 +++ src/lib/libc/rpc/clnt_vc.c Wed Dec 8 02:06:38 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: clnt_vc.c,v 1.16 2009/02/12 16:24:59 uebayasi Exp $ */ +/* $NetBSD: clnt_vc.c,v 1.17 2010/12/08 02:06:38 joerg Exp $ */ /* * Sun RPC is a product of Sun Microsystems, Inc. and is provided for @@ -36,7 +36,7 @@ static char *sccsid = "@(#)clnt_tcp.c 2.2 88/08/01 4.0 RPCSRC"; static char sccsid[] = "@(#)clnt_vc.c 1.19 89/03/16 Copyr 1988 Sun Micro"; #else -__RCSID("$NetBSD: clnt_vc.c,v 1.16 2009/02/12 16:24:59 uebayasi Exp $"); +__RCSID("$NetBSD: clnt_vc.c,v 1.17 2010/12/08 02:06:38 joerg Exp $"); #endif #endif @@ -126,7 +126,6 @@ */ #ifdef _REENTRANT static int *vc_fd_locks; -extern int __isthreaded; #define __rpc_lock_value __isthreaded; extern mutex_t clnt_fd_lock; static cond_t *vc_cv; Index: src/lib/libc/rpc/getnetconfig.c diff -u src/lib/libc/rpc/getnetconfig.c:1.17 src/lib/libc/rpc/getnetconfig.c:1.18 --- src/lib/libc/rpc/getnetconfig.c:1.17 Fri Apr 25 17:44:44 2008 +++ src/lib/libc/rpc/getnetconfig.c Wed Dec 8 02:06:38 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: getnetconfig.c,v 1.17 2008/04/25 17:44:44 christos Exp $ */ +/* $NetBSD: getnetconfig.c,v 1.18 2010/12/08 02:06:38 joerg Exp $ */ /* * Sun RPC is a product of Sun Microsystems, Inc. and is provided for @@ -35,7 +35,7 @@ #if 0 static char sccsid[] = "@(#)getnetconfig.c 1.12 91/12/19 SMI"; #else -__RCSID("$NetBSD: getnetconfig.c,v 1.17 2008/04/25 17:44:44 christos Exp $"); +__RCSID("$NetBSD: getnetconfig.c,v 1.18 2010/12/08 02:06:38 joerg Exp $"); #endif #endif @@ -160,7 +160,6 @@ __nc_error() { #ifdef _REENTRANT - extern int __isthreaded; int *nc_addr = NULL; #endif static int nc_error = 0; Index: src/lib/libc/rpc/mt_misc.c diff -u src/lib/libc/rpc/mt_misc.c:1.7 src/lib/libc/rpc/mt_misc.c:1.8 --- src/lib/libc/rpc/mt_misc.c:1.7 Mon Apr 28 20:23:00 2008 +++ src/lib/libc/rpc/mt_misc.c Wed Dec 8 02:06:38 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: mt_misc.c,v 1.7 2008/04/28 20:23:00 martin Exp $ */ +/* $NetBSD: mt_misc.c,v 1.8 2010/12/08 02:06:38 joerg Exp $ */ /*- * Copyright (c) 2004 The NetBSD Foundation, Inc. @@ -38,7 +38,7 @@ #include <sys/cdefs.h> #if defined(LIBC_SCCS) && !defined(lint) -__RCSID("$NetBSD: mt_misc.c,v 1.7 2008/04/28 20:23:00 martin Exp $"); +__RCSID("$NetBSD: mt_misc.c,v 1.8 2010/12/08 02:06:38 joerg Exp $"); #endif #include "namespace.h" @@ -116,7 +116,6 @@ { #ifdef _REENTRANT struct rpc_createerr *rce_addr = 0; - extern int __isthreaded; if (__isthreaded == 0) return (&rpc_createerr); Index: src/lib/libc/rpc/rpc_soc.c diff -u src/lib/libc/rpc/rpc_soc.c:1.12 src/lib/libc/rpc/rpc_soc.c:1.13 --- src/lib/libc/rpc/rpc_soc.c:1.12 Tue Nov 29 03:12:00 2005 +++ src/lib/libc/rpc/rpc_soc.c Wed Dec 8 02:06:38 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: rpc_soc.c,v 1.12 2005/11/29 03:12:00 christos Exp $ */ +/* $NetBSD: rpc_soc.c,v 1.13 2010/12/08 02:06:38 joerg Exp $ */ /* * Sun RPC is a product of Sun Microsystems, Inc. and is provided for @@ -43,7 +43,7 @@ #if 0 static char sccsid[] = "@(#)rpc_soc.c 1.41 89/05/02 Copyr 1988 Sun Micro"; #else -__RCSID("$NetBSD: rpc_soc.c,v 1.12 2005/11/29 03:12:00 christos Exp $"); +__RCSID("$NetBSD: rpc_soc.c,v 1.13 2010/12/08 02:06:38 joerg Exp $"); #endif #endif @@ -395,9 +395,6 @@ struct netconfig *nconf; /* Netconf of the transport */ { resultproc_t clnt_broadcast_result; -#ifdef _REENTRANT - extern int __isthreaded; -#endif _DIAGASSERT(resultp != NULL); _DIAGASSERT(addr != NULL); @@ -443,8 +440,6 @@ resultproc_t eachresult; /* call with each result obtained */ { #ifdef _REENTRANT - extern int __isthreaded; - if (__isthreaded == 0) clnt_broadcast_result_main = eachresult; else {