diff options
author | Philip Guenther <guenther@cvs.openbsd.org> | 2015-09-13 20:57:29 +0000 |
---|---|---|
committer | Philip Guenther <guenther@cvs.openbsd.org> | 2015-09-13 20:57:29 +0000 |
commit | b5cd2bc86b82c1add42e31fdc2939bd536d1d326 (patch) | |
tree | e318b8e56c2180f87c3efd9acab0920d48a69b3d /lib/libc | |
parent | 3fdbf6985630e7b8898f030e3ce0399e6bca7029 (diff) |
Wrap <rpcsvc/ypclnt.h> so that calls go direct and the symbols are all weak
Diffstat (limited to 'lib/libc')
-rw-r--r-- | lib/libc/hidden/rpcsvc/ypclnt.h | 37 | ||||
-rw-r--r-- | lib/libc/yp/yp_bind.c | 4 | ||||
-rw-r--r-- | lib/libc/yp/yp_first.c | 3 | ||||
-rw-r--r-- | lib/libc/yp/yp_get_default_domain.c | 3 | ||||
-rw-r--r-- | lib/libc/yp/ypmatch_cache.c | 4 | ||||
-rw-r--r-- | lib/libc/yp/ypprot_err.c | 3 |
6 files changed, 49 insertions, 5 deletions
diff --git a/lib/libc/hidden/rpcsvc/ypclnt.h b/lib/libc/hidden/rpcsvc/ypclnt.h new file mode 100644 index 00000000000..6a5aa7b8365 --- /dev/null +++ b/lib/libc/hidden/rpcsvc/ypclnt.h @@ -0,0 +1,37 @@ +/* $OpenBSD: ypclnt.h,v 1.1 2015/09/13 20:57:28 guenther Exp $ */ +/* + * Copyright (c) 2015 Philip Guenther <guenther@openbsd.org> + * + * Permission to use, copy, modify, and distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#ifndef _LIBC_RPCSVC_YPCLNT_H_ +#define _LIBC_RPCSVC_YPCLNT_H_ + +#include_next <rpcsvc/ypclnt.h> + +PROTO_NORMAL(_yp_dobind); +PROTO_DEPRECATED(yp_all); +PROTO_NORMAL(yp_bind); +PROTO_NORMAL(yp_first); +PROTO_NORMAL(yp_get_default_domain); +PROTO_DEPRECATED(yp_maplist); +PROTO_DEPRECATED(yp_master); +PROTO_NORMAL(yp_match); +PROTO_NORMAL(yp_next); +PROTO_DEPRECATED(yp_order); +PROTO_DEPRECATED(yp_unbind); +PROTO_DEPRECATED(yperr_string); +PROTO_NORMAL(ypprot_err); + +#endif /* _LIBC_RPCSVC_YPCLNT_H_ */ diff --git a/lib/libc/yp/yp_bind.c b/lib/libc/yp/yp_bind.c index 16216cc5294..a4d32678679 100644 --- a/lib/libc/yp/yp_bind.c +++ b/lib/libc/yp/yp_bind.c @@ -1,4 +1,4 @@ -/* $OpenBSD: yp_bind.c,v 1.23 2015/09/05 14:04:33 deraadt Exp $ */ +/* $OpenBSD: yp_bind.c,v 1.24 2015/09/13 20:57:28 guenther Exp $ */ /* * Copyright (c) 1992, 1993, 1996 Theo de Raadt <deraadt@theos.com> * All rights reserved. @@ -262,6 +262,7 @@ gotdata: *ypdb = ysd; return 0; } +DEF_WEAK(_yp_dobind); void _yp_unbind(struct dom_binding *ypb) @@ -276,6 +277,7 @@ yp_bind(const char *dom) { return _yp_dobind(dom, NULL); } +DEF_WEAK(yp_bind); void yp_unbind(const char *dom) diff --git a/lib/libc/yp/yp_first.c b/lib/libc/yp/yp_first.c index e631cc2e81f..2f24999043f 100644 --- a/lib/libc/yp/yp_first.c +++ b/lib/libc/yp/yp_first.c @@ -1,4 +1,4 @@ -/* $OpenBSD: yp_first.c,v 1.10 2015/01/16 16:48:51 deraadt Exp $ */ +/* $OpenBSD: yp_first.c,v 1.11 2015/09/13 20:57:28 guenther Exp $ */ /* * Copyright (c) 1992, 1993 Theo de Raadt <deraadt@theos.com> * All rights reserved. @@ -90,3 +90,4 @@ again: _yp_unbind(ysd); return r; } +DEF_WEAK(yp_first); diff --git a/lib/libc/yp/yp_get_default_domain.c b/lib/libc/yp/yp_get_default_domain.c index 2d72429fbcb..8cf0dc9fbd9 100644 --- a/lib/libc/yp/yp_get_default_domain.c +++ b/lib/libc/yp/yp_get_default_domain.c @@ -1,4 +1,4 @@ -/* $OpenBSD: yp_get_default_domain.c,v 1.8 2015/01/16 16:48:51 deraadt Exp $ */ +/* $OpenBSD: yp_get_default_domain.c,v 1.9 2015/09/13 20:57:28 guenther Exp $ */ /* * Copyright (c) 1992, 1993 Theo de Raadt <deraadt@theos.com> * All rights reserved. @@ -46,3 +46,4 @@ yp_get_default_domain(char **domp) return YPERR_NODOM; return 0; } +DEF_WEAK(yp_get_default_domain); diff --git a/lib/libc/yp/ypmatch_cache.c b/lib/libc/yp/ypmatch_cache.c index 8d2c65c5b49..718a1bde927 100644 --- a/lib/libc/yp/ypmatch_cache.c +++ b/lib/libc/yp/ypmatch_cache.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ypmatch_cache.c,v 1.16 2015/01/16 16:48:51 deraadt Exp $ */ +/* $OpenBSD: ypmatch_cache.c,v 1.17 2015/09/13 20:57:28 guenther Exp $ */ /* * Copyright (c) 1992, 1993 Theo de Raadt <deraadt@theos.com> * All rights reserved. @@ -209,6 +209,7 @@ out: _yp_unbind(ysd); return r; } +DEF_WEAK(yp_match); int yp_next(const char *indomain, const char *inmap, const char *inkey, @@ -268,3 +269,4 @@ again: _yp_unbind(ysd); return r; } +DEF_WEAK(yp_next); diff --git a/lib/libc/yp/ypprot_err.c b/lib/libc/yp/ypprot_err.c index 618d508b502..5c7660147be 100644 --- a/lib/libc/yp/ypprot_err.c +++ b/lib/libc/yp/ypprot_err.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ypprot_err.c,v 1.8 2015/01/16 16:48:51 deraadt Exp $ */ +/* $OpenBSD: ypprot_err.c,v 1.9 2015/09/13 20:57:28 guenther Exp $ */ /* * Copyright (c) 1992, 1993 Theo de Raadt <deraadt@theos.com> * All rights reserved. @@ -60,3 +60,4 @@ ypprot_err(unsigned int incode) } return YPERR_YPERR; } +DEF_WEAK(ypprot_err); |