diff --git a/net/libshout/Makefile b/net/libshout/Makefile index 016a2a00974..1501424d265 100644 --- a/net/libshout/Makefile +++ b/net/libshout/Makefile @@ -1,9 +1,9 @@ -# $OpenBSD: Makefile,v 1.4 2005/04/19 20:03:49 sturm Exp $ +# $OpenBSD: Makefile,v 1.5 2005/08/22 23:25:39 pvalchev Exp $ COMMENT= "library for communicating with an icecast server" DISTNAME= libshout-2.1 -PKGNAME= ${DISTNAME}p0 +PKGNAME= ${DISTNAME}p1 CATEGORIES= net audio HOMEPAGE= http://www.icecast.org/ diff --git a/net/libshout/patches/patch-src_util_c b/net/libshout/patches/patch-src_util_c index b29174e4f5d..a825841db5f 100644 --- a/net/libshout/patches/patch-src_util_c +++ b/net/libshout/patches/patch-src_util_c @@ -1,6 +1,6 @@ -$OpenBSD: patch-src_util_c,v 1.1 2005/04/19 20:07:11 sturm Exp $ ---- src/util.c.orig Sun Apr 17 12:25:31 2005 -+++ src/util.c Sun Apr 17 13:55:13 2005 +$OpenBSD: patch-src_util_c,v 1.2 2005/08/22 23:25:39 pvalchev Exp $ +--- src/util.c.orig Sun Mar 21 05:03:34 2004 ++++ src/util.c Fri Aug 19 21:04:04 2005 @@ -254,6 +254,7 @@ char *_shout_util_dict_urlencode(util_di char *res, *tmp; char *enc; @@ -54,7 +54,7 @@ $OpenBSD: patch-src_util_c,v 1.1 2005/04/19 20:07:11 sturm Exp $ free(enc); } -@@ -291,14 +310,24 @@ char *_shout_util_dict_urlencode(util_di +@@ -291,14 +310,25 @@ char *_shout_util_dict_urlencode(util_di return NULL; } @@ -67,12 +67,13 @@ $OpenBSD: patch-src_util_c,v 1.1 2005/04/19 20:07:11 sturm Exp $ - } else + } else { + int ret; ++ size_t reslen; res = tmp; - sprintf(res + strlen(res), "=%s", enc); - free(enc); -+ ret = snprintf(res + strlen(res), buflen - strlen(res), -+ "=%s", enc); -+ if (ret == -1 || ret >= buflen - strlen(res)) { ++ reslen = strlen(res); ++ ret = snprintf(res + reslen, buflen - reslen, "=%s", enc); ++ if (ret == -1 || ret >= buflen - reslen) { + free(enc); + free(res); + return NULL;