Skip to content

Some math is done here and there with time_t directly as an int #944

Open
@jimklimov

Description

@jimklimov

Parts of code such as upsmon assume that time_t is an integer or wider (which TBH it often is, but is not guaranteed to by standard) and compare timeouts elapsing, etc. by direct arithmetics. The portable way is to use difftime() or some such standard routines.

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-timeIssues and PRs about C/C++ methods, headers and data types dealing with timerefactor/fightwarnPR or issue proposal to improve code maintainability without functional changes, or to fix warnings

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions