Repository: go
Issue: x/image/tiff: sony .arw files decode as a 0x0 image.Gray
Labels: NeedsInvestigation

<!-- Please answer these questions before submitting your issue. Thanks! -->

### What version of Go are you using (`go version`)?

<pre>
$ go version
go version go1.13beta1 windows/amd64
</pre>

### Does this issue reproduce with the latest release?
yes


### What operating system and processor architecture are you using (`go env`)?

<details><summary><code>go env</code> Output</summary><br><pre>
$ go env
set GO111MODULE=
set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\Paolo\AppData\Local\go-build
set GOENV=C:\Users\Paolo\AppData\Roaming\go\env
set GOEXE=.exe
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GONOPROXY=
set GONOSUMDB=
set GOOS=windows
set GOPATH=C:\Users\Paolo\go
set GOPRIVATE=
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=c:\go
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=c:\go\pkg\tool\windows_amd64
set GCCGO=gccgo
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
set GOMOD=C:\Users\Paolo\Desktop\test\go.mod
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\Users\Paolo\AppData\Local\Temp\go-build477435338=/tmp/go-build -gno-record-gcc-switches
</pre></details>

### What did you do?

<!--
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.
-->
I installed the latest golang.org/x/image
I tried it on multiple .ARW files from different models but the issue occurs with all of them.

Sample image:
[_DSC4438.zip](https://github.com/golang/go/files/3513625/_DSC4438.zip)


```go
package main

import (
        "fmt"
        "image"
        "os"

        _ "golang.org/x/image/tiff"
)

func main() {
        f, err := os.Open("_DSC4438.ARW")
        if err != nil {
                panic(err)
        }

        img, format, err := image.Decode(f)
        f.Close()
        if err != nil {
                panic(err)
        }

        fmt.Printf("format: %s image: %#v width: %d height: %d", format, img, img.Bounds().Dx(), img.Bounds().Dy())
}

```

Result of running the code:
```
format: tiff image: &image.Gray{Pix:[]uint8{}, Stride:0, Rect:image.Rectangle{Min:image.Point{X:0, Y:0}, Max:image.Point{X:0, Y:0}}} width: 0 height: 0
```
</pre>

### What did you expect to see?
I expected to get an error when trying to decode the Sony .ARW raw image file, since Go doesn't know how to decode it.


### What did you see instead?
The image decode function returned no errors, and the image is incorrectly decoded as a 0 pixel image:
<pre>
&image.Gray{Pix:[]uint8{}, Stride:0, Rect:image.Rectangle{Min:image.Point{X:0, Y:0}, Max:image.Point{X:0, Y:0}}}
</pre>

The issue seems to have been introduced by https://github.com/golang/image/commit/7e034cad644213bc79b336b52fce73624259aeca since https://github.com/golang/image/commit/92942e4437e2b065806587df0f5d8afa565a8567 instead returns the following error when trying to decode the raw image:
<pre>
tiff: invalid format: BitsPerSample tag missing
</pre>