diff options
author | Sebastian Rasmussen <sebras@gmail.com> | 2012-03-11 12:01:34 +0100 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2012-03-12 13:28:51 +0000 |
commit | cfe5b48198b2f56049fcebad5c422c61fea9e97f (patch) | |
tree | bfb779d12d9a14d40a9ff25684ff994826296996 /draw | |
parent | b75dd982f18ce02781ce2a36e630860153f96ec9 (diff) | |
download | mupdf-cfe5b48198b2f56049fcebad5c422c61fea9e97f.tar.xz |
Remove unnecessary assignments.
Diffstat (limited to 'draw')
-rw-r--r-- | draw/draw_scale.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/draw/draw_scale.c b/draw/draw_scale.c index 489a2eb9..e758c989 100644 --- a/draw/draw_scale.c +++ b/draw/draw_scale.c @@ -349,16 +349,8 @@ add_weight(fz_weights *weights, int j, int i, fz_scale_filter *filter, weight = (int)(256*f+0.5f); /* Ensure i is in range */ - if (i < 0) - { - i = 0; + if (i < 0 || i >= src_w) return; - } - else if (i >= src_w) - { - i = src_w-1; - return; - } if (weight == 0) { /* We add a fudge factor here to allow for extreme downscales |