When DstMask is not nil, this shortcut causes stack overflow because Copy function in turn will call Scale with same dr and sr. Fixes golang/go#23107 Change-Id: I8ccadbd9b7f16363ac17b6114308527d6fa9456e Reviewed-on: https://go-review.googlesource.com/83537 Reviewed-by: Nigel Tao <nigeltao@golang.org> Run-TryBot: Nigel Tao <nigeltao@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>