summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMats O Jansson <maja@cvs.openbsd.org>2003-02-13 05:54:40 +0000
committerMats O Jansson <maja@cvs.openbsd.org>2003-02-13 05:54:40 +0000
commit946db0b3e6554405981ec89c49a0cd34680d7b86 (patch)
treec05883d4d84b3d07fecfad65bf22b01823e02811 /lib
parentc8d57efaa93616b636fce7c0d6cee74cc852b3eb (diff)
This fixes the problem with ypxfr switching key and value on map transfer.
This will make librpcsvc follow the real protocol and not the incorrect specification in yp.x. The changes in yp.x is from FreeBSD. A make build is the simplest way to get things working but the following five step is an alternative 1) make depend && make && make install in lib/librpcsvc 2) make includes in lib/librpcsvc 3) make depend && make && make install in lib/libc 4) make depend && make && make install in usr.sbin/ypserv/ypserv 5) make depend && make && make install in usr.sbin/ypserv/ypxfr -moj ok niklas@ ho@
Diffstat (limited to 'lib')
-rw-r--r--lib/librpcsvc/yp.x13
1 files changed, 11 insertions, 2 deletions
diff --git a/lib/librpcsvc/yp.x b/lib/librpcsvc/yp.x
index df2489e4f3f..9e81df14976 100644
--- a/lib/librpcsvc/yp.x
+++ b/lib/librpcsvc/yp.x
@@ -1,4 +1,4 @@
-/* $OpenBSD: yp.x,v 1.2 1997/08/19 07:54:52 niklas Exp $ */
+/* $OpenBSD: yp.x,v 1.3 2003/02/13 05:54:39 maja Exp $ */
/*
* Sun RPC is a product of Sun Microsystems, Inc. and is provided for
@@ -36,7 +36,7 @@
#ifndef RPC_HDR
%#ifndef lint
%/*static char sccsid[] = "from: @(#)yp.x 2.1 88/08/01 4.0 RPCSRC";*/
-%static char rcsid[] = "$OpenBSD: yp.x,v 1.2 1997/08/19 07:54:52 niklas Exp $";
+%static char rcsid[] = "$OpenBSD: yp.x,v 1.3 2003/02/13 05:54:39 maja Exp $";
%#endif /* not lint */
#endif
@@ -121,8 +121,13 @@ struct ypresp_val {
struct ypresp_key_val {
ypstat stat;
+#ifdef STUPID_SUN_BUG /* These are backwards */
keydat key;
valdat val;
+#else
+ valdat val;
+ keydat key;
+#endif
};
@@ -239,7 +244,11 @@ program YPPROG {
YPPROC_MATCH(ypreq_key) = 3;
ypresp_key_val
+#ifdef STUPID_SUN_BUG /* should be ypreq_nokey */
YPPROC_FIRST(ypreq_key) = 4;
+#else
+ YPPROC_FIRST(ypreq_nokey) = 4;
+#endif
ypresp_key_val
YPPROC_NEXT(ypreq_key) = 5;