Commit 59058bd45ff5dfea9f26776ae9465baa7496d8ac
1 parent
dc5c3b7f
KTS-3187
"Problem with opendir() in windows under indexerCore" Fixed. Committed By: Conrad Vermeulen Reviewed By: Martin Kirsten git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@8291 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing
2 changed files
with
5 additions
and
0 deletions
search2/indexing/indexerCore.inc.php
| @@ -612,6 +612,7 @@ abstract class Indexer | @@ -612,6 +612,7 @@ abstract class Indexer | ||
| 612 | $this->generalHookCache = array(); | 612 | $this->generalHookCache = array(); |
| 613 | $this->mimeHookCache = array(); | 613 | $this->mimeHookCache = array(); |
| 614 | 614 | ||
| 615 | + $this->hookPath = str_replace('\\','/', $this->hookPath); | ||
| 615 | $dir = opendir($this->hookPath); | 616 | $dir = opendir($this->hookPath); |
| 616 | while (($file = readdir($dir)) !== false) | 617 | while (($file = readdir($dir)) !== false) |
| 617 | { | 618 | { |
| @@ -1372,6 +1373,8 @@ abstract class Indexer | @@ -1372,6 +1373,8 @@ abstract class Indexer | ||
| 1372 | global $default; | 1373 | global $default; |
| 1373 | 1374 | ||
| 1374 | $diagnoses = array(); | 1375 | $diagnoses = array(); |
| 1376 | + | ||
| 1377 | + $path = str_replace('\\','/', $path); | ||
| 1375 | $dir = opendir($path); | 1378 | $dir = opendir($path); |
| 1376 | $extlen = - strlen($extension); | 1379 | $extlen = - strlen($extension); |
| 1377 | 1380 | ||
| @@ -1444,6 +1447,7 @@ abstract class Indexer | @@ -1444,6 +1447,7 @@ abstract class Indexer | ||
| 1444 | { | 1447 | { |
| 1445 | $this->clearExtractors(); | 1448 | $this->clearExtractors(); |
| 1446 | } | 1449 | } |
| 1450 | + $this->extractorPath = str_replace('\\','/', $this->extractorPath); | ||
| 1447 | $dir = opendir($this->extractorPath); | 1451 | $dir = opendir($this->extractorPath); |
| 1448 | while (($file = readdir($dir)) !== false) | 1452 | while (($file = readdir($dir)) !== false) |
| 1449 | { | 1453 | { |
search2/search/fieldRegistry.inc.php
| @@ -223,6 +223,7 @@ class ExprFieldRegistry | @@ -223,6 +223,7 @@ class ExprFieldRegistry | ||
| 223 | { | 223 | { |
| 224 | $this->fields = array(); | 224 | $this->fields = array(); |
| 225 | 225 | ||
| 226 | + $this->path = str_replace('\\','/', $this->path); | ||
| 226 | $dir = opendir($this->path); | 227 | $dir = opendir($this->path); |
| 227 | while (($file = readdir($dir)) !== false) | 228 | while (($file = readdir($dir)) !== false) |
| 228 | { | 229 | { |