diff options
author | Nigel Tao <nigeltao@golang.org> | 2011-07-12 17:02:55 +1000 |
---|---|---|
committer | Nigel Tao <nigeltao@golang.org> | 2011-07-12 17:02:55 +1000 |
commit | 04fb7960bdf6566438972ae2e280e954d6c09ca6 (patch) | |
tree | 32e1d6961cd9382ab6fa9bd510cab8104b090abe /src/pkg/image/draw/draw.go | |
parent | 0d6c6c958b8ccfa84978e088a8a9be297ce15a6f (diff) | |
download | go-04fb7960bdf6566438972ae2e280e954d6c09ca6.tar.gz |
image: remove superfluous if condition.
DrawMask already returns early if r.Empty().
R=r
CC=golang-dev
http://codereview.appspot.com/4703041
Diffstat (limited to 'src/pkg/image/draw/draw.go')
-rw-r--r-- | src/pkg/image/draw/draw.go | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/src/pkg/image/draw/draw.go b/src/pkg/image/draw/draw.go index 1583e6b88..a748ff8c7 100644 --- a/src/pkg/image/draw/draw.go +++ b/src/pkg/image/draw/draw.go @@ -193,9 +193,6 @@ func drawFillOver(dst *image.RGBA, r image.Rectangle, src *image.ColorImage) { } func drawFillSrc(dst *image.RGBA, r image.Rectangle, src *image.ColorImage) { - if r.Dy() < 1 { - return - } sr, sg, sb, sa := src.RGBA() // The built-in copy function is faster than a straightforward for loop to fill the destination with // the color, but copy requires a slice source. We therefore use a for loop to fill the first row, and |