pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/chat/ircII fix problem from upstream: avoid failing to...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/bae98c3d6d1a
branches:  trunk
changeset: 385695:bae98c3d6d1a
user:      mrg <mrg%pkgsrc.org@localhost>
date:      Wed Sep 26 10:38:26 2018 +0000

description:
fix problem from upstream: avoid failing to nul terminate strings, which
could lead to garbage being added to assignment values.

diffstat:

 chat/ircII/Makefile               |   4 ++--
 chat/ircII/distinfo               |   3 ++-
 chat/ircII/patches/patch-ircaux.c |  34 ++++++++++++++++++++++++++++++++++
 3 files changed, 38 insertions(+), 3 deletions(-)

diffs (70 lines):

diff -r 0572f17f3585 -r bae98c3d6d1a chat/ircII/Makefile
--- a/chat/ircII/Makefile       Wed Sep 26 05:41:43 2018 +0000
+++ b/chat/ircII/Makefile       Wed Sep 26 10:38:26 2018 +0000
@@ -1,11 +1,11 @@
-# $NetBSD: Makefile,v 1.79 2018/07/19 22:22:21 mrg Exp $
+# $NetBSD: Makefile,v 1.80 2018/09/26 10:38:26 mrg Exp $
 
 DISTNAME=              ircii-${VERS}
 PKGNAME=               ircII-${VERS}
 CATEGORIES=            chat
 MASTER_SITES=          http://ircii.warped.com/
 EXTRACT_SUFX=          .tar.bz2
-PKGREVISION=           1
+PKGREVISION=           2
 
 MAINTAINER=            pkgsrc-users%NetBSD.org@localhost
 HOMEPAGE=              http://www.eterna.com.au/ircii/
diff -r 0572f17f3585 -r bae98c3d6d1a chat/ircII/distinfo
--- a/chat/ircII/distinfo       Wed Sep 26 05:41:43 2018 +0000
+++ b/chat/ircII/distinfo       Wed Sep 26 10:38:26 2018 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.47 2018/07/19 22:22:21 mrg Exp $
+$NetBSD: distinfo,v 1.48 2018/09/26 10:38:26 mrg Exp $
 
 SHA1 (ircii-20170704.tar.bz2) = 88f55a59af48d7ed131895d68354fe7f566e3180
 RMD160 (ircii-20170704.tar.bz2) = b857a49c6d843748b0bcbccf9e3aec16d7be974b
@@ -6,4 +6,5 @@
 Size (ircii-20170704.tar.bz2) = 596535 bytes
 SHA1 (patch-ac) = 9f6f3b27670b63ff00b55c5431ec1da5219369ff
 SHA1 (patch-include_irc.h) = 257e7879461d88d9e8e05205e96cdec702e9e458
+SHA1 (patch-ircaux.c) = ab4d614cc20b3591a276b27ac818ed409c2116f6
 SHA1 (patch-source_names.c) = 53b22dcf43f274bb4a67c6ee016260e76c090756
diff -r 0572f17f3585 -r bae98c3d6d1a chat/ircII/patches/patch-ircaux.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/chat/ircII/patches/patch-ircaux.c Wed Sep 26 10:38:26 2018 +0000
@@ -0,0 +1,34 @@
+$NetBSD: patch-ircaux.c,v 1.1 2018/09/26 10:38:26 mrg Exp $
+
+avoid trailing garbage in some variable assignments.
+
+Index: source/ircaux.c
+===================================================================
+RCS file: /home/cvs/ircii/source/ircaux.c,v
+retrieving revision 1.123
+retrieving revision 1.124
+diff -p -u -r1.123 -r1.124
+--- source/ircaux.c    4 Jul 2017 12:10:22 -0000       1.123
++++ source/ircaux.c    13 Sep 2017 21:24:56 -0000      1.124
+@@ -946,7 +946,7 @@ double_quote_work(u_char *str, u_char *s
+       }
+       if (dst && pos < dstlen)
+               dst[pos] = '\0';
+-      return pos;
++      return pos + 1;
+ }
+ 
+ /*
+@@ -961,10 +961,10 @@ double_quote(u_char *str, u_char *stuff)
+       size_t len, len2;
+ 
+       len = double_quote_work(str, stuff, NULL, 0);
+-      if (len == 0)
++      if (len == 1)
+               return empty_string();
+ 
+-      dst = new_malloc(len + 1);
++      dst = new_malloc(len);
+       len2 = double_quote_work(str, stuff, dst, len);
+       if (len != len2)
+               yell("--- double_quote() error: len %zu len2 %zu", len, len2);



Home | Main Index | Thread Index | Old Index