Commit c45aac155fd682f9253e9e352a482facedde7add

Authored by Megan Watson
1 parent dc4c0df1

KTS-3337

"Text extractors using incorrect Python binary because of config.ini option"
Fixed. The stack is now checked before the config.ini option.

Committed by: Megan Watson
Reviewed by: Conrad Vermeulen



git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@8434 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing 1 changed file with 16 additions and 15 deletions
lib/util/ktutil.inc
... ... @@ -8,31 +8,31 @@
8 8 * Document Management Made Simple
9 9 * Copyright (C) 2008 KnowledgeTree Inc.
10 10 * Portions copyright The Jam Warehouse Software (Pty) Limited
11   - *
  11 + *
12 12 * This program is free software; you can redistribute it and/or modify it under
13 13 * the terms of the GNU General Public License version 3 as published by the
14 14 * Free Software Foundation.
15   - *
  15 + *
16 16 * This program is distributed in the hope that it will be useful, but WITHOUT
17 17 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
18 18 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
19 19 * details.
20   - *
  20 + *
21 21 * You should have received a copy of the GNU General Public License
22 22 * along with this program. If not, see <http://www.gnu.org/licenses/>.
23   - *
24   - * You can contact KnowledgeTree Inc., PO Box 7775 #87847, San Francisco,
  23 + *
  24 + * You can contact KnowledgeTree Inc., PO Box 7775 #87847, San Francisco,
25 25 * California 94120-7775, or email info@knowledgetree.com.
26   - *
  26 + *
27 27 * The interactive user interfaces in modified source and object code versions
28 28 * of this program must display Appropriate Legal Notices, as required under
29 29 * Section 5 of the GNU General Public License version 3.
30   - *
  30 + *
31 31 * In accordance with Section 7(b) of the GNU General Public License version 3,
32 32 * these Appropriate Legal Notices must retain the display of the "Powered by
33   - * KnowledgeTree" logo and retain the original copyright notice. If the display of the
  33 + * KnowledgeTree" logo and retain the original copyright notice. If the display of the
34 34 * logo is not reasonably feasible for technical reasons, the Appropriate Legal Notices
35   - * must display the words "Powered by KnowledgeTree" and retain the original
  35 + * must display the words "Powered by KnowledgeTree" and retain the original
36 36 * copyright notice.
37 37 * Contributor( s): ______________________________________
38 38 */
... ... @@ -727,6 +727,13 @@ class KTUtil {
727 727  
728 728 // {{{ findCommand
729 729 function findCommand($sConfigVar, $sDefault = null) {
  730 + // Check for the stack command before using the user defined command
  731 + $result = KTUtil::checkForStackCommand($sConfigVar);
  732 + if (!empty($result))
  733 + {
  734 + return $result;
  735 + }
  736 +
730 737 $oKTConfig =& KTConfig::getSingleton();
731 738 $sCommand = $oKTConfig->get($sConfigVar, $sDefault);
732 739 if (empty($sCommand)) {
... ... @@ -739,12 +746,6 @@ class KTUtil {
739 746 return $sCommand . ".exe";
740 747 }
741 748  
742   - $result = KTUtil::checkForStackCommand($sConfigVar);
743   - if (!empty($result))
744   - {
745   - return $result;
746   - }
747   -
748 749 $sExecSearchPath = $oKTConfig->get("KnowledgeTree/execSearchPath");
749 750 $sExecSearchPath .= PATH_SEPARATOR . KT_DIR . "/../common/";
750 751 $sExecSearchPath .= PATH_SEPARATOR . KT_DIR . "/../bin/xpdf/";
... ...