HomeClusterLabs Projects

Low: libcrmcommon: always mark durations appropriately

Description

Low: libcrmcommon: always mark durations appropriately

Previously, a crm_time_t would get marked as a duration if it was created with
crm_time_calculate_duration() but not if was created if crm_time_parse_duration().
Now it is correctly marked in the latter case.

Also ensure crm_duration_as_string() prints "0 seconds" for a 0-length
duration.

This fixes the case where a 0-length duration was given to iso8601.

Details

Provenance
kgaillotAuthored on Sep 26 2019, 5:36 PM
Parents
rPbfefdbbe29f7: Refactor: libcrmcommon: make parse_date() static
Branches
Unknown
Tags
Unknown

Event Timeline