Skip to content

Error 8192 while running under php7.4 #10

@hlh-restart

Description

@hlh-restart

First of all thank you for your superb work!!!

Here is the patch that solve this problem:

diff --git a/lib/TemplateRender.php b/lib/TemplateRender.php
index bf6e99d..249c7a1 100644
--- a/lib/TemplateRender.php
+++ b/lib/TemplateRender.php
@@ -200,7 +200,7 @@ class TemplateRender extends PageRender {
                                        $next_number = $vals;
 
                                        foreach ($mod as $calc) {
-                                               $operand = $calc{0};
+                                               $operand = $calc[0];
                                                $operator = substr ($calc,1);
 
                                                switch ($operand) {
diff --git a/lib/functions.php b/lib/functions.php
index e2f125c..f159f8c 100644
--- a/lib/functions.php
+++ b/lib/functions.php
@@ -1600,7 +1600,7 @@ function get_icon($server_id,$dn,$object_classes=array()) {
 
   # Return icon filename based upon objectClass value
   if (in_array('sambaaccount',$object_classes) &&
-    '$' == $rdn{ strlen($rdn) - 1 })
+    '$' == $rdn[ strlen($rdn) - 1 ])
     return 'nt_machine.png';
 
   if (in_array('sambaaccount',$object_classes))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions