summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorKurt <kurt.w.jung@gmail.com>2016-07-30 18:22:11 -0400
committerKurt <kurt.w.jung@gmail.com>2016-07-30 18:22:11 -0400
commitd7e9d2acda2e7a04390acec86f67f4fa9d732fa9 (patch)
tree3277fff01752fbf6017730046076d80d72d19459 /contrib
parentf4bda32520aac828bf0c3880a41a97d5db968a7c (diff)
Check for error in ghostscript example
Diffstat (limited to 'contrib')
-rw-r--r--contrib/ghostscript/ghostscript.go8
1 files changed, 6 insertions, 2 deletions
diff --git a/contrib/ghostscript/ghostscript.go b/contrib/ghostscript/ghostscript.go
index 2b695b8..3196c34 100644
--- a/contrib/ghostscript/ghostscript.go
+++ b/contrib/ghostscript/ghostscript.go
@@ -51,8 +51,12 @@ func min(name string) {
go func() {
errChan <- cmd.Start()
}()
- newPdf().Output(inPipe)
- report(name, <-errChan)
+ err = newPdf().Output(inPipe)
+ if err == nil {
+ report(name, <-errChan)
+ } else {
+ report(name, err)
+ }
} else {
report(name, err)
}