Package: python-numpy
VersionĀ : 1:1.1.0-3+lenny1
When using "numpy.fromfile" on a corrupted file, numpy runs
into an infinite loop with memory lack.
$ dpkg -s libc6 | grep ^Version
Version: 2.7-18
$ uname -r
2.6.29-2-amd64
$ cat corrupted.txt
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0,7
0,7
0.0
0.0
0.0
0.0
0.0
0.0
$ python
Python 2.5.2 (r252:60911, Jan 4 2009, 21:59:32)
[GCC 4.3.2] on linux2
>>> import numpy
>>> f = open('corrupted.txt')
>>> data = numpy.fromfile(f, dtype=float, count=-1, sep='\t')
The infinite loop can not be interrupted with "^C". One has to kill the
python process.
Note that in 'corrupted.txt' there is a '0,7' around line 10 while the
rest are only '0.0'.
This problem can not be reproduced on VersionĀ : 1:1.2.1-1.1
--
Emile Anclin <[email protected]>
http://www.logilab.fr/ http://www.logilab.org/
Informatique scientifique & et gestion de connaissances
_______________________________________________
Python-modules-team mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/python-modules-team