Commit d7f9d1ca authored by Nicolas Delaby's avatar Nicolas Delaby

_subprocess method is responsible to stop the timeout monitor.

No need to do it twice


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk/utils@42255 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 30a3355d
...@@ -164,8 +164,6 @@ class OOHandler: ...@@ -164,8 +164,6 @@ class OOHandler:
stdout, stderr = self._callUnoConverter(*['convert'], **kw) stdout, stderr = self._callUnoConverter(*['convert'], **kw)
finally: finally:
openoffice.release() openoffice.release()
if self.monitor.is_alive():
self._stopTimeout()
url = stdout.replace('\n', '') url = stdout.replace('\n', '')
self.document.reload(url) self.document.reload(url)
content = self.document.getContent(self.zip) content = self.document.getContent(self.zip)
...@@ -188,8 +186,6 @@ class OOHandler: ...@@ -188,8 +186,6 @@ class OOHandler:
stdout, stderr = self._callUnoConverter(*feature_list, **kw) stdout, stderr = self._callUnoConverter(*feature_list, **kw)
finally: finally:
openoffice.release() openoffice.release()
if self.monitor.is_alive():
self._stopTimeout()
metadata = json.loads(decodestring(stdout)) metadata = json.loads(decodestring(stdout))
if metadata.get("Data"): if metadata.get("Data"):
self.document.reload(metadata['Data']) self.document.reload(metadata['Data'])
...@@ -212,8 +208,6 @@ class OOHandler: ...@@ -212,8 +208,6 @@ class OOHandler:
stdout, stderr = self._callUnoConverter(*['setmetadata'], **kw) stdout, stderr = self._callUnoConverter(*['setmetadata'], **kw)
finally: finally:
openoffice.release() openoffice.release()
if self.monitor.is_alive():
self._stopTimeout()
doc_loaded = self.document.getContent() doc_loaded = self.document.getContent()
self.document.trash() self.document.trash()
return doc_loaded return doc_loaded
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment