From owner-freebsd-ports-bugs@FreeBSD.ORG Thu May 10 11:04:07 2012 Return-Path: Delivered-To: freebsd-ports-bugs@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 127ED1065670 for ; Thu, 10 May 2012 11:04:07 +0000 (UTC) (envelope-from ports@subnets.ru) Received: from mail.mega-net.ru (mail.mega-net.ru [91.217.137.1]) by mx1.freebsd.org (Postfix) with SMTP id 4FA428FC19 for ; Thu, 10 May 2012 11:04:05 +0000 (UTC) Received: (qmail 5809 invoked from network); 10 May 2012 14:57:21 +0400 Received: from unknown [172.16.10.37] (HELO work-book.lehis.ru) by mail.mega-net.ru with ESMTP; 10 May 2012 14:57:21 +0400 Message-ID: <4FAB9F12.6070702@subnets.ru> Date: Thu, 10 May 2012 14:57:22 +0400 From: "Alexey V. Panfilov" User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:12.0) Gecko/20120504 Thunderbird/12.0.1 MIME-Version: 1.0 To: FreeBSD-gnats-submit@FreeBSD.org, freebsd-ports-bugs@FreeBSD.org References: <201205101050.q4AAoAvg096186@freefall.freebsd.org> In-Reply-To: <201205101050.q4AAoAvg096186@freefall.freebsd.org> Content-Type: multipart/mixed; boundary="------------090800080601000900090905" Cc: Subject: Re: ports/167771: [patch] net-mgmt/mrtg fix rateup's coredump X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: ports@subnets.ru List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 10 May 2012 11:04:07 -0000 This is a multi-part message in MIME format. --------------090800080601000900090905 Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit Forgot add PORTREVISION to Makefile -- Simple Lehisnoe ;-) --------------090800080601000900090905 Content-Type: text/plain; charset=KOI8-R; name="mrtg_diff.txt" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="mrtg_diff.txt" diff -ruN mrtg.old/Makefile mrtg/Makefile --- mrtg/Makefile 2012-05-10 14:51:08.000000000 +0400 +++ mrtg/Makefile 2012-05-10 14:48:26.000000000 +0400 @@ -7,6 +7,7 @@ PORTNAME= mrtg PORTVERSION= 2.17.4 +PORTREVISION= 1 PORTEPOCH= 1 CATEGORIES= net-mgmt ipv6 MASTER_SITES= http://oss.oetiker.ch/mrtg/pub/ \ diff -ruN mrtg.old/files/patch-aaa.txt mrtg/files/patch-aaa.txt --- mrtg/files/patch-aaa.txt 1970-01-01 03:00:00.000000000 +0300 +++ mrtg/files/patch-aaa.txt 2012-05-10 14:34:05.000000000 +0400 @@ -0,0 +1,36 @@ +--- src/rateup.c.orig 2012-05-10 05:40:49.259760823 -0300 ++++ src/rateup.c 2012-05-10 05:44:32.297657818 -0300 +@@ -1132,9 +1132,10 @@ + gdImageDestroy (brush_outp); + free (lhist); + free (graph_label); +- if (kMG) ++ if (kMG) { + free(short_si); +- ++ short_si = short_si_def; ++ } + + #ifdef WIN32 + /* got to remove the target under win32 +@@ -1563,8 +1564,10 @@ + } + else + { +- strcpy (last.in, in); +- strcpy (last.out, out); ++ strncpy (last.in, in, MAXL); ++ last.in[MAXL-1]='\0'; ++ strncpy (last.out, out,MAXL); ++ last.out[MAXL-1]='\0'; + } + fprintf (fo, "%lu " LLD " " LLD " " LLD " " LLD "\n", + (unsigned long) now, inrate, outrate, inrate, outrate); +@@ -2114,6 +2117,7 @@ + history[x].in = rand () % atoi (argv[argi + 1]); + history[x].out = rand () % atoi (argv[argi + 2]); + } ++ /* fallthrough */ + case 'u': /* Update file */ + if (argv[argi][1] == 'p') + { --------------090800080601000900090905--