[X2Go-Commits] python-x2go.git - twofactorauth (branch) updated: 0.0.36.1-8-g5e21f99

X2Go dev team git-admin at x2go.org
Sat Sep 14 15:56:08 CEST 2013


The branch, twofactorauth has been updated
       via  5e21f99c3d71e85481486cfbbb035d2f80934a19 (commit)
      from  10c46349815fa1652ed0b98d86f3d5f14a46295e (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 x2go/printactions.py |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

The diff of changes is:
diff --git a/x2go/printactions.py b/x2go/printactions.py
index 3f084e5..130de95 100644
--- a/x2go/printactions.py
+++ b/x2go/printactions.py
@@ -191,7 +191,14 @@ class X2goPrintActionPDFVIEW(X2goPrintAction):
             shutil.copy2(pdf_file, _hr_filename)
             cmd_line = [ self.pdfview_cmd, _hr_filename, ]
             self.logger('viewing incoming PDF with command: %s' % ' '.join(cmd_line), loglevel=log.loglevel_DEBUG)
-            p = subprocess.Popen(cmd_line, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, env=_PRINT_ENV)
+            try:
+                p = subprocess.Popen(cmd_line, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, env=_PRINT_ENV)
+            except OSError, e:
+                if e.errno == 2:
+                    cmd_line = [ defaults.DEFAULT_PDFVIEW_CMD, _hr_filename ]
+                    p = subprocess.Popen(cmd_line, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, env=_PRINT_ENV)
+                else:
+                    raise(e)
             self.logger('waiting 20s longer before deleting the PDF file ,,%s\'\'' % _hr_filename, loglevel=log.loglevel_DEBUG)
             time.sleep(20)
             os.remove(_hr_filename)


hooks/post-receive
-- 
python-x2go.git (Python X2Go Client API)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "python-x2go.git" (Python X2Go Client API).




More information about the x2go-commits mailing list