projects
/
oweals
/
minetest.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8e4095f
)
ieee_float: Silence compiler warning
author
SmallJoker
<mk939@ymail.com>
Tue, 18 Dec 2018 18:50:07 +0000
(19:50 +0100)
committer
SmallJoker
<mk939@ymail.com>
Tue, 18 Dec 2018 18:50:07 +0000
(19:50 +0100)
Trivial issue reported by @pgimeno
src/util/ieee_float.cpp
patch
|
blob
|
history
diff --git
a/src/util/ieee_float.cpp
b/src/util/ieee_float.cpp
index e7909360f1d5bd8843a7a76a70b8269c48681b94..887258921b125757b116546d06e9f1260e3e99ba 100644
(file)
--- a/
src/util/ieee_float.cpp
+++ b/
src/util/ieee_float.cpp
@@
-70,7
+70,7
@@
u32 f32Tou32Slow(f32 f)
return signbit | 0x7FC00000UL;
if (std::isinf(f))
return signbit | 0x7F800000UL;
- int exp
;
+ int exp
= 0; // silence warning
f32 mant = frexpf(f, &exp);
u32 imant = (u32)std::floor((signbit ? -16777216.f : 16777216.f) * mant);
exp += 126;