summaryrefslogtreecommitdiff
path: root/tests/test_tools/functional_tests.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_tools/functional_tests.php')
-rw-r--r--tests/test_tools/functional_tests.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/test_tools/functional_tests.php b/tests/test_tools/functional_tests.php
index 73bd6226..151f77db 100644
--- a/tests/test_tools/functional_tests.php
+++ b/tests/test_tools/functional_tests.php
@@ -4,8 +4,11 @@ $TEST_TOOLS = dirname(__FILE__);
if(isset($_GET['sr']))
{
-
- if(($selenium_resource=realpath($TEST_TOOLS.'/selenium/'.$_GET['sr']))!==false)
+ $selenium_base=$TEST_TOOLS.'/selenium/';
+ $selenium_resource=realpath($selenium_base.$_GET['sr']);
+
+ if($selenium_resource!==false &&
+ strpos($selenium_resource, $selenium_base) === 0)
echo file_get_contents($selenium_resource);
exit;
}