summaryrefslogtreecommitdiff
path: root/databases/pgbadger/files
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--databases/pgbadger/files/patch-Makefile.PL6
-rw-r--r--databases/pgbadger/files/patch-pgbadger22
2 files changed, 25 insertions, 3 deletions
diff --git a/databases/pgbadger/files/patch-Makefile.PL b/databases/pgbadger/files/patch-Makefile.PL
index ff336ed38eab..5d39cb52fbda 100644
--- a/databases/pgbadger/files/patch-Makefile.PL
+++ b/databases/pgbadger/files/patch-Makefile.PL
@@ -1,6 +1,6 @@
---- Makefile.PL.orig 2018-09-13 11:03:46.086169000 +0200
-+++ Makefile.PL 2018-09-13 11:03:58.018702000 +0200
-@@ -45,13 +45,13 @@
+--- Makefile.PL.orig 2025-03-16 11:52:30 UTC
++++ Makefile.PL
+@@ -55,13 +55,13 @@ doc/synopsis.pod: Makefile pgbadger
echo "=head1 SYNOPSIS" > $@
./pgbadger --help >> $@
echo "=head1 DESCRIPTION" >> $@
diff --git a/databases/pgbadger/files/patch-pgbadger b/databases/pgbadger/files/patch-pgbadger
new file mode 100644
index 000000000000..f469e209e9ea
--- /dev/null
+++ b/databases/pgbadger/files/patch-pgbadger
@@ -0,0 +1,22 @@
+fix Possible precedence problem between ! and string eq
+
+--- pgbadger.orig 2025-07-13 10:08:32 UTC
++++ pgbadger
+@@ -20462,7 +20462,7 @@ sub highlight_code
+ # lowercase/uppercase known functions or words followed by an open parenthesis
+ # if the token is not a keyword, an open parenthesis or a comment
+ if (($self->_is_function( $token, $last_token, $next_token ) && $next_token eq '(')
+- || (!$self->_is_keyword( $token, $next_token, $last_token ) && !$next_token eq '('
++ || (!$self->_is_keyword( $token, $next_token, $last_token ) && $next_token ne '('
+ && $token ne '(' && !$self->_is_comment( $token )) ) {
+ if ($self->{ 'uc_functions' } == 1) {
+ $token = '<span class="kw2_l">' . $token . '</span>';
+@@ -23062,7 +23062,7 @@ sub _add_token
+ # if the token is not a keyword, an open parenthesis or a comment
+ my $fct = $self->_is_function( $token, $last_token, $next_token ) || '';
+ if (($fct and $next_token eq '(' and defined $last_token and uc($last_token) ne 'CREATE')
+- or (!$self->_is_keyword( $token, $next_token, $last_token ) and !$next_token eq '('
++ or (!$self->_is_keyword( $token, $next_token, $last_token ) and $next_token ne '('
+ and $token ne '(' and !$self->_is_comment( $token )) )
+ {
+ $token =~ s/$fct/\L$fct\E/i if ( $self->{ 'uc_functions' } == 1 );