git://wimlib.net
/
wimlib
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
81d03c5
)
lzms_common.h: add cast needed if sizeof(int) > sizeof(u32)
author
Eric Biggers
<ebiggers3@gmail.com>
Fri, 5 Feb 2016 01:19:08 +0000
(19:19 -0600)
committer
Eric Biggers
<ebiggers3@gmail.com>
Tue, 9 Feb 2016 01:43:11 +0000
(19:43 -0600)
include/wimlib/lzms_common.h
patch
|
blob
|
history
diff --git
a/include/wimlib/lzms_common.h
b/include/wimlib/lzms_common.h
index 56e351109546a0db14e821203de58758b6b0c16e..6db35b77fcbad1cc432fa8165545589d6b3b155d 100644
(file)
--- a/
include/wimlib/lzms_common.h
+++ b/
include/wimlib/lzms_common.h
@@
-119,7
+119,7
@@
lzms_get_probability(const struct lzms_probability_entry *prob_entry)
* if (prob == 0)
* prob++;
*/
* if (prob == 0)
* prob++;
*/
- prob += (prob - 1) >> 31;
+ prob += (
u32)(
prob - 1) >> 31;
/*
* if (prob == LZMS_PROBABILITY_DENOMINATOR)
/*
* if (prob == LZMS_PROBABILITY_DENOMINATOR)