summaryrefslogtreecommitdiffstats
path: root/application/libraries/Pygments.php
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2015-11-23 14:43:55 +0100
committerFlorian Pritz <bluewind@xinu.at>2015-11-23 14:43:55 +0100
commit9c695761a303b7cf1b37905bda3395ed60adeb30 (patch)
treed2a04ffe1e3eb75b6cdc43ca087e4bf47759f7f4 /application/libraries/Pygments.php
parent9eed447539bb2c2bdab13a2306c2be36963df37b (diff)
l/Pygments: Fix exception for filenames ending with a dot
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'application/libraries/Pygments.php')
-rw-r--r--application/libraries/Pygments.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/application/libraries/Pygments.php b/application/libraries/Pygments.php
index 5d37b69c3..81963bc68 100644
--- a/application/libraries/Pygments.php
+++ b/application/libraries/Pygments.php
@@ -173,6 +173,9 @@ class Pygments {
if (strpos($this->filename, ".") !== false) {
$extension = substr($this->filename, strrpos($this->filename, ".") + 1);
+ if ($extension === false) {
+ return false;
+ }
$extensionarray = array(
'awk' => 'awk',