Skip to content

Commit

Permalink
PHP: Added hidden preference for PHP interpreter output timeout - fixes
Browse files Browse the repository at this point in the history
#1684

Some PHP versions may take longer than the hord-coded 5 seconds to initialize.
Changed this into a preference.

rn=
  • Loading branch information
mitchell-as committed Jul 1, 2016
1 parent 8a4c64f commit 83dae67
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/koAppInfo.py
Expand Up @@ -842,7 +842,7 @@ def _GetPHPOutputAndError(self, phpCode, php=None):
log.error("Caught PHP execution exception: %s", e.strerror)
return None, e.strerror
try:
p.wait(5)
p.wait(self._prefs.getLong("phpGetOutputAndErrorTimeout", 5))
except process.ProcessError:
# Timed out.
log.error("PHP command timed out: %r", argv)
Expand Down
1 change: 1 addition & 0 deletions src/prefs/prefs.p.xml
Expand Up @@ -178,6 +178,7 @@
<string id="phpCommentStyle">//,#</string>
<boolean id="phpDoubleClickSelectsEntireVariable">1</boolean>
<boolean id="phpLintWithINIFile">1</boolean>
<long id="phpGetOutputAndErrorTimeout">5</long>

<!-- Additional directories for Python, Perl, etc. These are
stored as pathsep-separated local paths. -->
Expand Down

0 comments on commit 83dae67

Please sign in to comment.