Skip to content

Commit

Permalink
Fixed parsing error where 'day,' is ignored
Browse files Browse the repository at this point in the history
  • Loading branch information
Aidan committed Jun 5, 2024
1 parent 29699cd commit 62e5850
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion host/host_aix.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func UptimeWithContext(ctx context.Context) (uint64, error) {
var days uint64 = 0
var hours uint64 = 0
var minutes uint64 = 0
if ut[3] == "days," {
if ut[3] == "day," || ut[3] == "days," {
days, err = strconv.ParseUint(ut[2], 10, 64)
if err != nil {
return 0, err
Expand Down

0 comments on commit 62e5850

Please sign in to comment.