From a83722285fc9a853464e6f9792e30c32457479b4 Mon Sep 17 00:00:00 2001 From: brad Date: Tue, 5 Jul 2005 01:40:45 +0000 Subject: [PATCH] add patches from mbalmer@ to fix the config parser on powerpc. --- net/silc-server/Makefile | 8 +--- .../patches/patch-lib_silcutil_silcconfig_c | 42 +++++++++++++++++++ .../patches/patch-lib_silcutil_silcutil_c | 12 ++++++ 3 files changed, 56 insertions(+), 6 deletions(-) create mode 100644 net/silc-server/patches/patch-lib_silcutil_silcconfig_c create mode 100644 net/silc-server/patches/patch-lib_silcutil_silcutil_c diff --git a/net/silc-server/Makefile b/net/silc-server/Makefile index 65359fb2931..f2753215168 100644 --- a/net/silc-server/Makefile +++ b/net/silc-server/Makefile @@ -1,13 +1,9 @@ -# $OpenBSD: Makefile,v 1.18 2005/04/07 00:49:18 brad Exp $ - -.if ${MACHINE_ARCH} == "powerpc" -BROKEN= "config file parser bug on ${MACHINE_ARCH}" -.endif +# $OpenBSD: Makefile,v 1.19 2005/07/05 01:40:45 brad Exp $ COMMENT= "Secure Internet Live Conferencing (SILC) server" DISTNAME= silc-server-0.9.19p1 -PKGNAME= silc-server-0.9.19.1 +PKGNAME= silc-server-0.9.19.1p1 CATEGORIES= net HOMEPAGE= http://www.silcnet.org/ diff --git a/net/silc-server/patches/patch-lib_silcutil_silcconfig_c b/net/silc-server/patches/patch-lib_silcutil_silcconfig_c new file mode 100644 index 00000000000..8ca77cdf41b --- /dev/null +++ b/net/silc-server/patches/patch-lib_silcutil_silcconfig_c @@ -0,0 +1,42 @@ +$OpenBSD: patch-lib_silcutil_silcconfig_c,v 1.1 2005/07/05 01:40:45 brad Exp $ +--- lib/silcutil/silcconfig.c.orig Mon Jul 4 21:17:54 2005 ++++ lib/silcutil/silcconfig.c Mon Jul 4 21:19:22 2005 +@@ -94,7 +94,7 @@ char *silc_config_strerror(int errnum) + /* Points the first non-space character */ + static void my_trim_spaces(SilcConfigFile *file) + { +- register char *r = file->p; ++ signed char *r = file->p; + while ((*r != '\0' && *r != EOF) && isspace(*r)) + if (*r++ == '\n') file->line++; + file->p = r; +@@ -102,7 +102,7 @@ static void my_trim_spaces(SilcConfigFil + /* Skips the current line until newline (lf or cr) */ + static void my_skip_line(SilcConfigFile *file) + { +- register char *r = file->p; ++ signed char *r = file->p; + while ((*r != '\0' && *r != EOF) && (*r != '\n') && (*r != '\r')) r++; + file->p = ((*r != '\0' && *r != EOF) ? r + 1 : r); + file->line++; +@@ -321,9 +321,9 @@ SilcUInt32 silc_config_get_line(SilcConf + + char *silc_config_read_line(SilcConfigFile *file, SilcUInt32 line) + { +- register char *p; ++ signed char *p; + int len; +- char *ret = NULL, *endbuf; ++ signed char *ret = NULL, *endbuf; + + if (!file || (line <= 0)) + return NULL; +@@ -446,7 +446,7 @@ bool silc_config_register_table(SilcConf + static int silc_config_main_internal(SilcConfigEntity ent) + { + SilcConfigFile *file = ent->file; +- char **p = &file->p; ++ signed char **p = &file->p; + + /* loop throught statements */ + while (1) { diff --git a/net/silc-server/patches/patch-lib_silcutil_silcutil_c b/net/silc-server/patches/patch-lib_silcutil_silcutil_c new file mode 100644 index 00000000000..677d452397c --- /dev/null +++ b/net/silc-server/patches/patch-lib_silcutil_silcutil_c @@ -0,0 +1,12 @@ +$OpenBSD: patch-lib_silcutil_silcutil_c,v 1.1 2005/07/05 01:40:45 brad Exp $ +--- lib/silcutil/silcutil.c.orig Mon Jul 4 21:19:32 2005 ++++ lib/silcutil/silcutil.c Mon Jul 4 21:20:00 2005 +@@ -45,7 +45,7 @@ int silc_gets(char *dest, int destlen, c + + dest[i] = src[start]; + +- if (dest[i] == EOF) ++ if ((signed char)dest[i] == EOF) + return EOF; + + if (dest[i] == '\n')