From f553c537b423ecdbe5c639906986218b2561146c Mon Sep 17 00:00:00 2001 From: mappu Date: Thu, 24 Nov 2016 20:53:26 +1300 Subject: [PATCH] imagequant: fix panic --- Image.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Image.go b/Image.go index 37e48a1..55c7b71 100644 --- a/Image.go +++ b/Image.go @@ -38,7 +38,9 @@ func (this *Image) Release() { } func (this *Image) Quantize(attr *Attributes) (*Result, error) { - res := Result{} + res := Result{ + im: this, + } liqerr := C.liq_image_quantize(this.p, attr.p, &res.p) if liqerr != C.LIQ_OK { return nil, translateError(liqerr)