POV-Ray : Newsgroups : povray.beta-test : Linux Beta 28 segfaults on Slackware and Kubuntu : Re: Linux Beta 28 segfaults on Slackware and Kubuntu Server Time
29 Apr 2024 12:57:25 EDT (-0400)
  Re: Linux Beta 28 segfaults on Slackware and Kubuntu  
From: Chris Cason
Date: 18 Sep 2008 07:22:21
Message: <48d239ed$1@news.povray.org>
geep999 wrote:
> 1611                                    lcc.tested = true;

Good work in picking this up: looking at the code it's fairly clear what's
happening. Since the test (lcc.tested == false) isn't segfaulting but the
assignment is, the memory must have been freed during TraceShadowRay(). The
only thing that would cause that is a re-alloc of the cache via resize(),
which is exactly what's done in ComputeShadowColor().

Suggestion: as an experiment, try changing the initial value of the cache
(line 153) to a much larger value and see if the fault goes away. I suspect
it will (note this is not the solution, just a test: the solution is to
either avoid the need to resize, or to not keep references to the data
across calls to the trace functions).

-- Chris


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.