mirror of
https://github.com/nmap/nmap.git
synced 2026-08-03 22:29:06 +00:00
Change 10 to 10.0 in pow() calls to make it clear that it is a double
This commit is contained in:
parent
d46395db25
commit
b9d845b9ab
1 changed files with 2 additions and 2 deletions
|
|
@ -1331,8 +1331,8 @@ static char *num_to_string_sigdigits(double d, unsigned int digits) {
|
|||
shift = -digits;
|
||||
} else {
|
||||
shift = floor(log10(fabs(d))) - digits + 1;
|
||||
d = floor(d / pow(10, shift) + 0.5);
|
||||
d = d * pow(10, shift);
|
||||
d = floor(d / pow(10.0, shift) + 0.5);
|
||||
d = d * pow(10.0, shift);
|
||||
}
|
||||
|
||||
n = Snprintf(buf, sizeof(buf), "%.*f", MAX(0, -shift), d);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue