On Fri 19/02/2016 21:43, Jérémie Courrèges-Anglas wrote:
> 
> Thanks.  The problem is that the iterator is invalidated by erase(); the
> diff ensures that after erase() returns, pit points at the previous item
> in the list.
> 
> oks?
> 
> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/x11/bbpager/Makefile,v
> retrieving revision 1.18
> diff -u -p -r1.18 Makefile
> --- Makefile  28 Oct 2014 08:18:30 -0000      1.18
> +++ Makefile  19 Feb 2016 20:42:34 -0000
> @@ -3,7 +3,7 @@
>  COMMENT =    pager for the Blackbox window manager
>  
>  DISTNAME =   bbpager-0.4.7
> -REVISION=    1
> +REVISION=    2
>  
>  CATEGORIES = x11
>  MASTER_SITES =       ${MASTER_SITE_SOURCEFORGE:=bbtools/}
> Index: patches/patch-src_wminterface_cxx
> ===================================================================
> RCS file: patches/patch-src_wminterface_cxx
> diff -N patches/patch-src_wminterface_cxx
> --- /dev/null 1 Jan 1970 00:00:00 -0000
> +++ patches/patch-src_wminterface_cxx 19 Feb 2016 20:42:34 -0000
> @@ -0,0 +1,13 @@
> +$OpenBSD$
> +--- src/wminterface.cxx.orig Fri Feb 19 19:14:47 2016
> ++++ src/wminterface.cxx      Fri Feb 19 19:15:04 2016
> +@@ -84,8 +84,7 @@ void WMInterface::updateWindowList(void)
> +         for (; pit != pit_end; pit++) {
> +             if (!(*pit)->isMarked()) {
> +                 delete (*pit);
> +-                bbtool->pagerWindowList().erase(pit);
> +-                pit--;
> ++                bbtool->pagerWindowList().erase(pit--);
> +             } else {
> +             }
> +         }
> 
> 

Confirmed: this patch solves the problem on -current, amd64.

Thanks a lot

-- 
Alessandro DE LAURENZIS
[mailto:just22....@gmail.com]
LinkedIn: http://it.linkedin.com/in/delaurenzis

Reply via email to