Skip to content

bug(printf): big hex values, lead to mismatch in outputs last two digits when paired with rounding #13867

Description

@HackingRepo

Hi, uutils mainteners

we confirm that part of our testing, here is how can be repro

relunsec@relunsec:~/software/coreutils/target/debug$ ./printf %.f1 -0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
-1053122916685571866979180276836704323188950954005491112543109775351relunsec@relunsec:~/software/coreutils/target/debug$ gnuprintf %.f1 -0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
-1053122916685571866979180276836704323188950954005491112543109775361relunsec@relunsec:~/software/coreutils/target/debug$ 

as you can see uu says 51 gnu says 61, that also with the same value when removing the - sign

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions