projects
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
e703b46
)
Protect against gcc's "warning: cast does not match function type".
author
Geoff Thorpe
<geoff@openssl.org>
Thu, 25 Mar 2004 02:19:42 +0000
(
02:19
+0000)
committer
Geoff Thorpe
<geoff@openssl.org>
Thu, 25 Mar 2004 02:19:42 +0000
(
02:19
+0000)
crypto/bio/b_print.c
patch
|
blob
|
history
diff --git
a/crypto/bio/b_print.c
b/crypto/bio/b_print.c
index decefc22767c34a6524c0cab4f292b2d868ac828..47b04396d76e24ea87b4be10e494f0e8ba2e6232 100644
(file)
--- a/
crypto/bio/b_print.c
+++ b/
crypto/bio/b_print.c
@@
-619,6
+619,7
@@
fmtfp(
int caps = 0;
long intpart;
long fracpart;
int caps = 0;
long intpart;
long fracpart;
+ long max10;
if (max < 0)
max = 6;
if (max < 0)
max = 6;
@@
-639,11
+640,12
@@
fmtfp(
/* we "cheat" by converting the fractional part to integer by
multiplying by a factor of 10 */
/* we "cheat" by converting the fractional part to integer by
multiplying by a factor of 10 */
- fracpart = roundv((pow10(max)) * (ufvalue - intpart));
+ max10 = roundv(pow10(max));
+ fracpart = roundv(pow10(max) * (ufvalue - intpart));
- if (fracpart >=
(long)pow10(max)
) {
+ if (fracpart >=
max10
) {
intpart++;
intpart++;
- fracpart -=
(long)pow10(max)
;
+ fracpart -=
max10
;
}
/* convert integer part */
}
/* convert integer part */