Merge lp:~openerp-dev/openobject-addons/5.0-opw-381924-rgo into lp:openobject-addons/5.0

Proposed by Ravi Gohil (OpenERP)
Status: Merged
Approved by: Naresh(OpenERP)
Approved revision: no longer in the source branch.
Merged at revision: 2934
Proposed branch: lp:~openerp-dev/openobject-addons/5.0-opw-381924-rgo
Merge into: lp:openobject-addons/5.0
Diff against target: 11 lines (+1/-0)
1 file modified
document/content_index.py (+1/-0)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/5.0-opw-381924-rgo
Reviewer Review Type Date Requested Status
Naresh(OpenERP) (community) Approve
Review via email: mp+91613@code.launchpad.net

Description of the change

Hello,

When we create an attachment with .pdf file extension, a copy is been created in /tmp(temporary) folder of ubuntu system and stays in the system until rebooted or manually deleted.

This fixes the issue.

Thanks.

To post a comment you must log in.
Revision history for this message
Naresh(OpenERP) (nch-openerp) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'document/content_index.py'
2--- document/content_index.py 2009-09-03 12:50:00 +0000
3+++ document/content_index.py 2012-02-06 07:23:20 +0000
4@@ -56,6 +56,7 @@
5 fp = os.popen('pdftotext -enc UTF-8 -nopgbrk '+file_name+' -', 'r')
6 result = fp.read()
7 fp.close()
8+ os.unlink(file_name)
9 elif ext in ('.xls','.ods','.odt','.odp'):
10 s = StringIO.StringIO(content)
11 o = odt2txt.OpenDocumentTextFile(s)