From owner-freebsd-ports-bugs@FreeBSD.ORG Sun Jun 15 15:40:01 2008 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8750B106566C for ; Sun, 15 Jun 2008 15:40:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 681A58FC1A for ; Sun, 15 Jun 2008 15:40:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id m5FFe0Gl077758 for ; Sun, 15 Jun 2008 15:40:00 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m5FFe0Ch077757; Sun, 15 Jun 2008 15:40:00 GMT (envelope-from gnats) Resent-Date: Sun, 15 Jun 2008 15:40:00 GMT Resent-Message-Id: <200806151540.m5FFe0Ch077757@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Fabian Keil Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 12A7D106567A for ; Sun, 15 Jun 2008 15:35:28 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 062138FC14 for ; Sun, 15 Jun 2008 15:35:28 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.2/8.14.2) with ESMTP id m5FFZMPl036241 for ; Sun, 15 Jun 2008 15:35:27 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.2/8.14.1/Submit) id m5FFZMS0036240; Sun, 15 Jun 2008 15:35:22 GMT (envelope-from nobody) Message-Id: <200806151535.m5FFZMS0036240@www.freebsd.org> Date: Sun, 15 Jun 2008 15:35:22 GMT From: Fabian Keil To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/124616: [PATCH] Prevent audio/mp3splt from segfaulting if vorbis file is split after mp3 file X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Jun 2008 15:40:01 -0000 >Number: 124616 >Category: ports >Synopsis: [PATCH] Prevent audio/mp3splt from segfaulting if vorbis file is split after mp3 file >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sun Jun 15 15:40:00 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Fabian Keil >Release: CURRENT >Organization: >Environment: FreeBSD TP51.local 8.0-CURRENT FreeBSD 8.0-CURRENT #22: Wed Jun 11 18:12:28 CEST 2008 fk@TP51.local:/usr/obj/usr/src/sys/THINKPAD i386 >Description: audio/mp3splt segfaults if a vorbis file is split after a mp3 file. The attached patch prevents that. I already reported the problem upstream: https://sourceforge.net/tracker/?func=detail&atid=476061&aid=1953386&group_id=55130 but it seems that they are busy rewriting mp3splt, thus the old one is no longer actively maintained and waiting for a new release may take a while. >How-To-Repeat: fk@TP51 /tank/iriver-spiegel/podcasts/split $mp3splt -t 5.00 ../bsdtalk14* Mp3Splt 2.1c (2005/Apr/03) by Matteo Trotta THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR OWN RISK! ./bsdtalk143.mp3: MPEG 1 Layer 3 - 44100 Hz - Mono - 64 Kb/s - Total time: 22m.45s Splitting bsdtalk143_000.00_005.00.mp3... OK [...] Splitting bsdtalk143_020.00_025.00.mp3... OK (WARNING) Warning: mp3 might be VBR. You should use -f option. ./bsdtalk143.ogg: Ogg Vorbis Stream - 44100 - 93 Kb/s - 1 channels - Total time: 22m.45s Splitting bsdtalk143_000.00_005.00.ogg... OK [...] Splitting bsdtalk143_020.00_025.00.ogg... OK (EOF) ./bsdtalk144.mp3: Segmentation fault: 11 (core dumped) >Fix: Patch attached with submission follows: diff -u -ruN mp3splt.orig/Makefile mp3splt/Makefile --- mp3splt.orig/Makefile 2008-02-07 16:09:10.100268000 +0100 +++ mp3splt/Makefile 2008-06-15 16:52:12.058673649 +0200 @@ -7,7 +7,7 @@ PORTNAME= mp3splt PORTVERSION= 2.1c -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= audio MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} MASTER_SITE_SUBDIR= ${PORTNAME} diff -u -ruN mp3splt.orig/files/patch-mp3splt.c mp3splt/files/patch-mp3splt.c --- mp3splt.orig/files/patch-mp3splt.c 1970-01-01 01:00:00.000000000 +0100 +++ mp3splt/files/patch-mp3splt.c 2008-04-27 21:07:59.025871032 +0200 @@ -0,0 +1,16 @@ +--- mp3splt.c.orig 2005-03-26 14:51:56.000000000 +0100 ++++ mp3splt.c 2008-04-27 21:05:45.396787349 +0200 +@@ -114,6 +114,13 @@ + if (state->mstate) { + fclose(state->mstate->file_input); + mp3_state_free(state->mstate); ++ /* ++ * Explicitly setting mstate to NULL ++ * prevents encoding misdetection (resulting ++ * in a crash) if a mp3 file is followed by ++ * a vorbis file. ++ */ ++ state->mstate = NULL; + } + #ifndef NO_OGG + else if (state->ostate) { // If file has been opened with ov_open we should close it using ov_clear() >Release-Note: >Audit-Trail: >Unformatted: