Skip to content

Commit

Permalink
Fixes #12151: Rudder agent history prints errors on stderr on aix
Browse files Browse the repository at this point in the history
  • Loading branch information
peckpeck committed Feb 26, 2018
1 parent b5d9133 commit 111f9a8
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions share/lib/reports.awk
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,11 @@ function print_report_multiline() {
if (!original_time) {
if (match(r[9], /##/)) { # match the first ##
original_time = substr(r[9],0,RSTART-1)
# Needed to correctly eval complete command with some versions of awk
command = "date +%s.%N -d \"" original_time "\""
command | getline original_time_s;
if (!broken_date) {
# Needed to correctly eval complete command with some versions of awk
command = "date +%s.%N -d \"" original_time "\""
command | getline original_time_s;
}
}
}
}
Expand Down

0 comments on commit 111f9a8

Please sign in to comment.