mirror of
https://github.com/talgo-cloud/bimg.git
synced 2026-03-08 15:08:16 -07:00
commit
66f3ccc217
3 changed files with 11 additions and 4 deletions
|
|
@ -1,3 +1,7 @@
|
|||
## 1.0.1 / 22-06-2016
|
||||
|
||||
- fix(#90): Do not not dereference the original image a second time.
|
||||
|
||||
## 1.0.0 / 21-04-2016
|
||||
|
||||
- refactor(api): breaking changes: normalize public members to follow Go naming idioms.
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
package bimg
|
||||
|
||||
// Version represents the current package semantic version.
|
||||
const Version = "1.0.0"
|
||||
const Version = "1.0.1"
|
||||
|
|
|
|||
9
vips.go
9
vips.go
|
|
@ -318,9 +318,12 @@ func vipsSave(image *C.VipsImage, o vipsSaveOptions) ([]byte, error) {
|
|||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
//When an image has an unsupported color space, vipsPreSave returns the pointer of the image passed to it unmodified.
|
||||
//When this occurs, we must take care to not dereference the original image a second time;
|
||||
//we may otherwise erroneously free the object twice
|
||||
|
||||
// When an image has an unsupported color space, vipsPreSave
|
||||
// returns the pointer of the image passed to it unmodified.
|
||||
// When this occurs, we must take care to not dereference the
|
||||
// original image a second time; we may otherwise erroneously
|
||||
// free the object twice.
|
||||
if tmpImage != image {
|
||||
defer C.g_object_unref(C.gpointer(tmpImage))
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue