From owner-freebsd-ports@FreeBSD.ORG Mon Apr 29 20:57:39 2013 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 620357FE for ; Mon, 29 Apr 2013 20:57:39 +0000 (UTC) (envelope-from khorben@defora.org) Received: from mahce.defora.org (mahce.defora.org [176.28.20.185]) by mx1.freebsd.org (Postfix) with ESMTP id 27E6F1FDC for ; Mon, 29 Apr 2013 20:57:38 +0000 (UTC) Received: by mahce.defora.org (Postfix, from userid 1000) id 78B871A87C02D; Mon, 29 Apr 2013 22:50:32 +0200 (CEST) Date: Mon, 29 Apr 2013 22:50:32 +0200 From: Pierre Pronchery To: Matthias Apitz Subject: Re: astro/foxtrotgps (1.1.1_1 from ports SVN r315646) crashes on start Message-ID: <20130429205032.GO3880@defora.org> References: <20130428180134.GA1770@tiny.Sisis.de> <20130429154031.GA2206@tinyCurrent> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20130429154031.GA2206@tinyCurrent> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: crwhipp@gmail.com, freebsd-ports@freebsd.org X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Apr 2013 20:57:39 -0000 Hey, On Mon, Apr 29, 2013 at 05:40:32PM +0200, Matthias Apitz wrote: > El día Sunday, April 28, 2013 a las 08:01:35PM +0200, Matthias Apitz escribió: > > > Foxtrotgps crashes on start on 10-CURRENT r235646 during 'pthread_mutex_unlock', > > details follow below; > > The attached patch (to be placed in astro/foxtrotgps/files/patch-src-main > before 'make install') fixes the bug; thank you for the patch, it fixes the reproducible crash upon startup, and I have committed it to pkgsrc-wip. However, I am afraid that it may break functionality, and allow only the main Gtk+ thread to start. Map download in particular was performed in a separate thread in TangoGPS IIRC, and here foxtrot doesn't download anything... I'm afraid this issue results from the patch. It may be more work than just this to get it to run properly :/ Please let me know if it works better for you. Cheers, -- khorben > --- src/main.c.orig 2012-06-14 06:41:11.000000000 +0200 > +++ src/main.c 2013-04-29 17:19:50.000000000 +0200 > @@ -200,9 +200,17 @@ > > init(); > > - gtk_main (); > - > - > - > + /* Properly call gdk_threads_enter() and gdk_threads_leave() to prevent > + abort() on startup due to gtk trying to unlock a uninitialized > + mutex > + see also: http://openbsd.7691.n7.nabble.com/geo-tangogps-abort-trap-td147777.html > + */ > + > + gdk_threads_enter(); > + > + gtk_main (); > + > + gdk_threads_leave(); > + > return 0; > } -- khorben