[pkg-nagios-changes] [Git][nagios-team/nagvis][master] 4 commits: New upstream version 1.9.40

Bas Couwenberg (@sebastic) gitlab at salsa.debian.org
Wed Jan 10 13:24:08 GMT 2024



Bas Couwenberg pushed to branch master at Debian Nagios Maintainer Group / nagvis


Commits:
2946a7d7 by Bas Couwenberg at 2024-01-10T14:21:24+01:00
New upstream version 1.9.40
- - - - -
f9871deb by Bas Couwenberg at 2024-01-10T14:21:29+01:00
Update upstream source from tag 'upstream/1.9.40'

Update to upstream version '1.9.40'
with Debian dir dfd64143748e0dcc414bb76aeda6c687328ec3cf
- - - - -
5b27f5dd by Bas Couwenberg at 2024-01-10T14:21:53+01:00
New upstream release.

- - - - -
787ffb34 by Bas Couwenberg at 2024-01-10T14:22:39+01:00
Set distribution to unstable.

- - - - -


4 changed files:

- ChangeLog
- debian/changelog
- share/server/core/defines/global.php
- share/server/core/ext/php-gettext-1.0.12/plurals.php


Changes:

=====================================
ChangeLog
=====================================
@@ -1,3 +1,7 @@
+1.9.40
+Core:
+  * FIX: Fix PHP 5.4 and 5.5 compatibility issue (Fatal error: Arrays are not allowed in class constants)
+
 1.9.39
 Core:
   * FIX: Fix PHP 5.4 compatibility issue (syntax error, unexpected ':', expecting '{' in)


=====================================
debian/changelog
=====================================
@@ -1,3 +1,10 @@
+nagvis (1:1.9.40-1) unstable; urgency=medium
+
+  * Team upload.
+  * New upstream release.
+
+ -- Bas Couwenberg <sebastic at debian.org>  Wed, 10 Jan 2024 14:22:30 +0100
+
 nagvis (1:1.9.39-1) unstable; urgency=medium
 
   * Team upload.


=====================================
share/server/core/defines/global.php
=====================================
@@ -23,7 +23,7 @@
  *****************************************************************************/
  
 // NagVis Version
-define('CONST_VERSION', '1.9.39');
+define('CONST_VERSION', '1.9.40');
 
 // Set PHP error handling to standard level
 // Different levels for php versions below 5.1 because PHP 5.1 reports


=====================================
share/server/core/ext/php-gettext-1.0.12/plurals.php
=====================================
@@ -141,9 +141,9 @@ class PluralsExpression {
   private $operator;
   private $operands;
 
-  const BINARY_OPERATORS = [
+  private static $BINARY_OPERATORS = [
     '==', '!=', '>=', '<=', '&&', '||', '+', '-', '*', '/', '%', '>', '<'];
-  const UNARY_OPERATORS = ['!'];
+  private static $UNARY_OPERATORS = ['!'];
 
   /**
    * Constructor
@@ -156,9 +156,9 @@ class PluralsExpression {
    * PluralExpression. Unary operators expect one operand, binary operators
    * expect two operands and trinary operators expect three operands.
    */
-  public function __construct($operator, ...$operands) {
+  public function __construct($operator, $operand1 = null, $operand2 = null, $operand3 = null) {
     $this->operator = $operator;
-    $this->operands = $operands;
+    $this->operands = array($operand1, $operand2, $operand3);
   }
 
   /**
@@ -170,11 +170,11 @@ class PluralsExpression {
   public function to_string() {
     if ($this->operator == 'const' || $this->operator == 'var') {
       return $this->operands[0];
-    } elseif (in_array($this->operator, self::BINARY_OPERATORS)) {
+    } elseif (in_array($this->operator, self::$BINARY_OPERATORS)) {
       return sprintf(
         "(%s %s %s)", $this->operands[0]->to_string(), $this->operator,
         $this->operands[1]->to_string());
-    } elseif (in_array($this->operator, self::UNARY_OPERATORS)) {
+    } elseif (in_array($this->operator, self::$UNARY_OPERATORS)) {
       return sprintf(
         "(%s %s)", $this->operator, $this->operands[0]->to_string());
     } elseif ($this->operator == '?') {
@@ -197,7 +197,7 @@ class PluralsExpression {
     if (!in_array($this->operator, ['const', 'var'])) {
       $operand1 = $this->operands[0]->evaluate($n);
     }
-    if (in_array($this->operator, self::BINARY_OPERATORS) ||
+    if (in_array($this->operator, self::$BINARY_OPERATORS) ||
         $this->operator == '?') {
       $operand2 = $this->operands[1]->evaluate($n);
     }
@@ -259,14 +259,14 @@ class PluralsParser {
    * 0. However, ':' and ')' exist here to make sure that parsing does not
    * proceed beyond them when they are not to be parsed.
    */
-  private const PREC = [
+  private static $PREC = [
     ':' => -1, '?' => 0, '||' => 1, '&&' => 2, '==' => 3, '!=' => 3,
     '>' => 4, '<' => 4, '>=' => 4, '<=' => 4, '+' => 5, '-' => 5, '*' => 6,
     '/' => 6, '%' => 6, '!' => 7, '__END__' => -1, ')' => -1
   ];
 
   // List of right associative operators
-  private const RIGHT_ASSOC = ['?'];
+  private static $RIGHT_ASSOC = ['?'];
 
   /**
    * Constructor
@@ -326,7 +326,7 @@ class PluralsParser {
         $token = $this->lexer->fetch_token();
     }
 
-    if ($token !== NULL && !array_key_exists($token, self::PREC)) {
+    if ($token !== NULL && !array_key_exists($token, self::$PREC)) {
       throw new Exception('Operator expected');
     }
     return $token;
@@ -349,7 +349,7 @@ class PluralsParser {
   private function _parse($left_side, $min_precedence) {
     $next_token = $this->_parse_operator(true);
 
-    while (self::PREC[$next_token] >= $min_precedence) {
+    while (self::$PREC[$next_token] >= $min_precedence) {
       $operator = $this->_parse_operator(false);
       $right_side = $this->_parse_primary();
 
@@ -359,11 +359,11 @@ class PluralsParser {
        * Consume (recursively) into right hand side all expressions of higher
        * precedence.
        */
-      while ((self::PREC[$operator] < self::PREC[$next_token]) ||
-             ((self::PREC[$operator] == self::PREC[$next_token]) &&
-              in_array($operator, self::RIGHT_ASSOC))) {
+      while ((self::$PREC[$operator] < self::$PREC[$next_token]) ||
+             ((self::$PREC[$operator] == self::$PREC[$next_token]) &&
+              in_array($operator, self::$RIGHT_ASSOC))) {
         $right_side = $this->_parse(
-            $right_side, self::PREC[$next_token]);
+            $right_side, self::$PREC[$next_token]);
         $next_token = $this->_parse_operator(true);
       }
 
@@ -381,7 +381,7 @@ class PluralsParser {
         }
 
         $right_side2 = $this->_parse(
-          $this->_parse_primary(), self::PREC[$operator] + 1);
+          $this->_parse_primary(), self::$PREC[$operator] + 1);
         $next_token = $this->_parse_operator(true);
         $left_side = new PluralsExpression(
             '?', $left_side, $right_side, $right_side2);



View it on GitLab: https://salsa.debian.org/nagios-team/nagvis/-/compare/0cd3708952c38aa7f914464e595c14b92b34fdf5...787ffb34169ea6ab481869f0eeaf8a071a96239c

-- 
View it on GitLab: https://salsa.debian.org/nagios-team/nagvis/-/compare/0cd3708952c38aa7f914464e595c14b92b34fdf5...787ffb34169ea6ab481869f0eeaf8a071a96239c
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-nagios-changes/attachments/20240110/de8ac0cc/attachment-0001.htm>


More information about the pkg-nagios-changes mailing list