Closed andypost closed 4 years ago
Hello @andypost,
Thank you for the report. It looks like long
on 32-bit PHP installations is only 32-bit, but GType (the thing returned by vips_type_from_name("VipsBlob")
) is 64.
I think we have to change the type of vips_image_set_type()
from:
long vips_image_set_type(resource image, integer gtype, string field, mixed value)
To:
long vips_image_set_type(resource image, string type, string field, mixed value)
ie. we put the string -> GType conversion into set_type. It'll be a bit slower, but it avoids exposing GType to PHP.
We could allow both integer and string, of course, perhaps that's the best solution. What do you think?
I went for string names for types. Hopefully this fixes it.
Thanks again for the report!
Thanks, gonna try patch today
1.0.12 now pass all https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/11839/pipelines
That's great! Thank you for testing.
Just used to upgrade to 1.0.11 and test
tests/042.phpt
started to fail 32-bits on x86 and armv7It means that it fails somehow according to https://github.com/libvips/php-vips-ext/blob/master/vips.c#L1636
PS: here's CI runs