[Scipy-tickets] [SciPy] #1330: special.specfun.jdzo array access out of bounds

SciPy Trac scipy-tickets@scipy....
Tue Nov 23 15:07:06 CST 2010


#1330: special.specfun.jdzo array access out of bounds
---------------------------+------------------------------------------------
 Reporter:  dagss          |       Owner:  pv   
     Type:  defect         |      Status:  new  
 Priority:  normal         |   Milestone:  0.9.0
Component:  scipy.special  |     Version:  0.8.0
 Keywords:                 |  
---------------------------+------------------------------------------------
Changes (by pv):

  * owner:  somebody => pv
  * priority:  high => normal
  * component:  Other => scipy.special


Comment:

 The code seems to assume that the caller has declared
 {{{
         double precision zo(0:NT)
 }}}
 for calling the function. This is visible e.g. in the fact that otherwise
 the output appears to contain an off-by-one error. (This indexing
 peculiarity also seems to be forgotten in `jnjnp_zeros`.)

 The other initialization statement required to silence Valgrind is
 `ZOC(0)=0`.
 Adding this seems also to remove the out-of-bounds indexing, and ensure
 correct output.

-- 
Ticket URL: <http://projects.scipy.org/scipy/ticket/1330#comment:3>
SciPy <http://www.scipy.org>
SciPy is open-source software for mathematics, science, and engineering.


More information about the Scipy-tickets mailing list