From de158f8fdf1d4198d6fcd16f5078b5eac861ba0a Mon Sep 17 00:00:00 2001 From: Heimdal Developers Date: Tue, 5 Oct 2010 08:20:03 +0100 Subject: [PATCH] Import of code from heimdal This commit updates the code imported from the external heimdal git repository to their revision 48ad3e1e6597f03cce5439831ef94b5ec11894e9 which is described as switch-from-svn-to-git-1593-g48ad3e1 Change-Id: I0fda4dcf7c7e06de70636969c2f3242b9de714be Reviewed-on: http://gerrit.openafs.org/2907 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- src/external/heimdal/roken/vwarn.c | 43 +++++++++++++++++++++++++++++++++++ src/external/heimdal/roken/vwarnx.c | 43 +++++++++++++++++++++++++++++++++++ src/external/heimdal/roken/warn.c | 45 +++++++++++++++++++++++++++++++++++++ src/external/heimdal/roken/warnx.c | 6 ++--- 4 files changed, 134 insertions(+), 3 deletions(-) create mode 100644 src/external/heimdal/roken/vwarn.c create mode 100644 src/external/heimdal/roken/vwarnx.c create mode 100644 src/external/heimdal/roken/warn.c diff --git a/src/external/heimdal/roken/vwarn.c b/src/external/heimdal/roken/vwarn.c new file mode 100644 index 0000000..8f1706d --- /dev/null +++ b/src/external/heimdal/roken/vwarn.c @@ -0,0 +1,43 @@ +/* + * Copyright (c) 1995 - 2001 Kungliga Tekniska Högskolan + * (Royal Institute of Technology, Stockholm, Sweden). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * 3. Neither the name of the Institute nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include + +#include "roken.h" +#include + +ROKEN_LIB_FUNCTION void ROKEN_LIB_CALL +vwarn(const char *fmt, va_list ap) +{ + rk_warnerr(1, fmt, ap); +} diff --git a/src/external/heimdal/roken/vwarnx.c b/src/external/heimdal/roken/vwarnx.c new file mode 100644 index 0000000..5c6b1c1 --- /dev/null +++ b/src/external/heimdal/roken/vwarnx.c @@ -0,0 +1,43 @@ +/* + * Copyright (c) 1995 - 2001 Kungliga Tekniska Högskolan + * (Royal Institute of Technology, Stockholm, Sweden). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * 3. Neither the name of the Institute nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include + +#include "roken.h" +#include + +ROKEN_LIB_FUNCTION void ROKEN_LIB_CALL +vwarnx(const char *fmt, va_list ap) +{ + rk_warnerr(0, fmt, ap); +} diff --git a/src/external/heimdal/roken/warn.c b/src/external/heimdal/roken/warn.c new file mode 100644 index 0000000..09b9cf8 --- /dev/null +++ b/src/external/heimdal/roken/warn.c @@ -0,0 +1,45 @@ +/* + * Copyright (c) 1995, 1996, 1997 Kungliga Tekniska Högskolan + * (Royal Institute of Technology, Stockholm, Sweden). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * 3. Neither the name of the Institute nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include + +#include "err.h" + +void +warn(const char *fmt, ...) +{ + va_list ap; + va_start(ap, fmt); + vwarn(fmt, ap); + va_end(ap); +} diff --git a/src/external/heimdal/roken/warnx.c b/src/external/heimdal/roken/warnx.c index 09b9cf8..cf33939 100644 --- a/src/external/heimdal/roken/warnx.c +++ b/src/external/heimdal/roken/warnx.c @@ -35,11 +35,11 @@ #include "err.h" -void -warn(const char *fmt, ...) +ROKEN_LIB_FUNCTION void ROKEN_LIB_CALL +warnx(const char *fmt, ...) { va_list ap; va_start(ap, fmt); - vwarn(fmt, ap); + vwarnx(fmt, ap); va_end(ap); } -- 1.9.4