View Issue Details

IDProjectCategoryView StatusLast Update
0000589FreeCADBugpublic2012-02-07 12:23
Reporterms4pyAssigned To 
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
Product Version 
Target VersionFixed in Version0.13 
Summary0000589: Some files are not properly closed
DescriptionSome part of FreeCAD opens temporary files and does not properly close them. A long term running Python script which makes some FreeCAD API calls results always in the following error:

OSError: [Errno 24] Too many open files

Looking with `lsof` at the process shows *a lot* of open files like the following:

python2.6 14603 ms4py 612u REG 8,1 2930 1998969 /tmp/filezSyDlu (deleted)
python2.6 14603 ms4py 613u REG 8,1 2774 1998970 /tmp/file5H0Tos (deleted)

These files are obviously created with FileInfo::getTempFileName, but I couldn't track where the files are actually opened.

Platform: CAELinux 2011 (Ubuntu 10.04 64bit)
FreeCAD: 0.13, rev4972
TagsNo tags attached.

Activities

ms4py

2012-02-05 18:42

reporter   ~0001612

Same issue with freecad-daily (rev5070).

wmayer

2012-02-06 10:45

administrator   ~0001613

Is there a certain procedure to force this problem to appear?

wmayer

2012-02-07 12:22

administrator   ~0001615

It seems that the function mkstemp() already opens a tmp. file and there is a constant TMP_MAX which says how many tmp. files can be opened at a time.

wmayer

2012-02-07 12:23

administrator   ~0001616

Should be fixed with git commit a592f55473226f5bf91538359516623a0cdfea77

Issue History

Date Modified Username Field Change
2012-02-05 18:36 ms4py New Issue
2012-02-05 18:42 ms4py Note Added: 0001612
2012-02-06 10:45 wmayer Note Added: 0001613
2012-02-07 12:22 wmayer Note Added: 0001615
2012-02-07 12:23 wmayer Note Added: 0001616
2012-02-07 12:23 wmayer Status new => closed
2012-02-07 12:23 wmayer Resolution open => fixed
2012-02-07 12:23 wmayer Fixed in Version => 0.13