Matt McCutchen's Web Site
/
rsync
/
rsync.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
067669d
)
Fixed the multiplying of blength*blength so that it can't overflow
author
Wayne Davison
<wayned@samba.org>
Fri, 22 Aug 2003 05:42:13 +0000
(
05:42
+0000)
committer
Wayne Davison
<wayned@samba.org>
Fri, 22 Aug 2003 05:42:13 +0000
(
05:42
+0000)
before it gets cast to a uint64.
generator.c
patch
|
blob
|
blame
|
history
diff --git
a/generator.c
b/generator.c
index
f2e7c71
..
48273f0
100644
(file)
--- a/
generator.c
+++ b/
generator.c
@@
-155,7
+155,7
@@
static void sum_sizes_sqroot_baarda(struct sum_struct *sum, uint64 len)
blength = 0;
do {
blength |= c;
- if (len < (uint64)
(blength * blength)
)
+ if (len < (uint64)
blength * blength
)
blength &= ~c;
c >>= 1;
} while (c >= 8); /* round to multiple of 8 */