octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #44406] glps_renderer::draw uses static state


From: John W. Eaton
Subject: [Octave-bug-tracker] [bug #44406] glps_renderer::draw uses static state variable, potential bug?
Date: Mon, 02 Mar 2015 14:33:47 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Firefox/31.0 Iceweasel/31.2.0

Follow-up Comment #2, bug #44406 (project octave):

An unwind_protect object is just a C++ object that stores data and associated
actions.  It doesn't suspend signal delivery.

The unwind_protect destructor will execute at the end of the enclosing scope,
then whatever actions have been attached to it will be performed at that time.
 Interrupts ultimately cause a C++ exception to be thrown, so unwind_protect
destructor would be called in that case too.

The unwind_protect object in the scope that calls glps_renderer::draw doesn't
do anything about restoring the value of the static variable in_draw.  It
looks to me like an unwind_protect object is needed there too.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?44406>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]