summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKurt Jung <kurt.w.jung@code.google.com>2013-08-25 21:55:23 -0400
committerKurt Jung <kurt.w.jung@code.google.com>2013-08-25 21:55:23 -0400
commitecf65dac9ed0a7648b02b2ae037e14cfce0919dd (patch)
treed5e6bb7f66abd04ee8f5f3c9a9e18d0bbf621c8d
parent5591db1df1ec5d5a357755e6f3c40172b9609529 (diff)
Removed debugging code, specifically the dump function that uses the spew package. Thanks, Anthony.
-rw-r--r--fpdf.go4
-rw-r--r--util.go20
2 files changed, 9 insertions, 15 deletions
diff --git a/fpdf.go b/fpdf.go
index 1bd2530..7b286a2 100644
--- a/fpdf.go
+++ b/fpdf.go
@@ -1978,10 +1978,6 @@ func (f *Fpdf) Output(w io.Writer) error {
if err != nil {
f.err = err
}
- dump("pdf.txt", f.stdPageSizes,
- f.defPageSize,
- f.curPageSize,
- f.pageSizes)
return f.err
}
diff --git a/util.go b/util.go
index 823bf68..86ddd37 100644
--- a/util.go
+++ b/util.go
@@ -20,8 +20,7 @@ import (
"bytes"
"compress/zlib"
"fmt"
- "github.com/davecgh/go-spew/spew"
- // "io/ioutil"
+ // "github.com/davecgh/go-spew/spew"
"math"
"os"
"regexp"
@@ -224,12 +223,11 @@ func strIf(cnd bool, aStr, bStr string) string {
}
// Dump the internals of the specified values
-func dump(fileStr string, a ...interface{}) {
- fl, err := os.OpenFile(fileStr, os.O_CREATE|os.O_APPEND|os.O_WRONLY, 0600)
- if err == nil {
- fmt.Fprintf(fl, "----------------\n")
- spew.Fdump(fl, a...)
- fl.Close()
- }
- // ioutil.WriteFile(fileStr, []byte(spew.Sdump(a)), os.ModeAppend)
-}
+// func dump(fileStr string, a ...interface{}) {
+// fl, err := os.OpenFile(fileStr, os.O_CREATE|os.O_APPEND|os.O_WRONLY, 0600)
+// if err == nil {
+// fmt.Fprintf(fl, "----------------\n")
+// spew.Fdump(fl, a...)
+// fl.Close()
+// }
+// }