mirror of https://github.com/dsoprea/go-exif.git
exif-read-tool: Make no-exif error nicer for tool
parent
bd04addaf4
commit
1e1e1ed104
|
@ -78,7 +78,14 @@ func main() {
|
||||||
log.PanicIf(err)
|
log.PanicIf(err)
|
||||||
|
|
||||||
rawExif, err := exif.SearchAndExtractExif(data)
|
rawExif, err := exif.SearchAndExtractExif(data)
|
||||||
log.PanicIf(err)
|
if err != nil {
|
||||||
|
if err == exif.ErrNoExif {
|
||||||
|
fmt.Printf("No EXIF data.\n")
|
||||||
|
os.Exit(1)
|
||||||
|
}
|
||||||
|
|
||||||
|
log.Panic(err)
|
||||||
|
}
|
||||||
|
|
||||||
// Run the parse.
|
// Run the parse.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue