[haiku-appserver] Re: some help please

  • From: Stefano Ceccherini <burton666@xxxxxxxxxxx>
  • To: haiku-appserver@xxxxxxxxxxxxx
  • Date: 19 Sep 2005 08:59:47 -0000

First of all, sorry for the delay.

>That being said, it looks very much like an algorithmical >problem in the 
>BRegion code, which the failing ASSERT reveals. I haven't dug >deep enough 
>into the code to understand it completely -- I guess, it's >much easier for 
>Stefano to have a look 

Uh, I guess, even if you already did a good work without me, it seems :P

>-- but what I have understood so far >is that 
>BRegion::Support::OrRegionComplex() slices the plane into >horizontal bands, 
>and invokes ROr() for each one. 

Yes, exactly.

>What apparently can happen >is, that such a 
>band doesn't intersect with any of the rects in the two given >regions. Which 
>is exactly the case when the ASSERT is violated.

Good catch.

>The solution would either be to check for empty bands in >OrRegionComplex() 
>and skip them, or instead of the ASSERT in ROr() simply >return in case of 
>foundCount == 0 at that point. I tried the latter, and it >seems to work well 

Yeah I think you can go with the latter solution (even as a temporary 
solution). I'll try to have a look to see what triggered that bug. At least I 
had never seen it before, but it may well be that was just because I almost 
never compile the whole tree with DEBUG=1.

Stefano Ceccherini aka Jack Burton
Non resistere alla tentazione di conoscere nuovi amori!
Oltre 1.800.000 persone ti stanno aspettando su Incontri.
Vivi le emozioni fino in fondo!

Other related posts: