when reading PROP_UNIT, check it's value against the number of built-in
2000-04-26 Michael Natterer <mitch@gimp.org> * app/xcf.c (xcf_load_image_props): when reading PROP_UNIT, check it's value against the number of built-in units, not against the number of defined units.
This commit is contained in:
parent
5bca88b5e8
commit
f084945e77
@ -1,3 +1,9 @@
|
||||
2000-04-26 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* app/xcf.c (xcf_load_image_props): when reading PROP_UNIT, check
|
||||
it's value against the number of built-in units, not against the
|
||||
number of defined units.
|
||||
|
||||
Wed Apr 26 11:04:12 PDT 2000 Manish Singh <yosh@gimp.org>
|
||||
|
||||
* gimptool.in: typo fix
|
||||
|
@ -1923,7 +1923,7 @@ xcf_load_image_props (XcfInfo *info,
|
||||
info->cp += xcf_read_int32 (info->fp, &unit, 1);
|
||||
|
||||
if ((unit <= GIMP_UNIT_PIXEL) ||
|
||||
(unit >= gimp_unit_get_number_of_units()))
|
||||
(unit >= gimp_unit_get_number_of_built_in_units()))
|
||||
{
|
||||
g_message ("Warning, unit out of range in XCF file, falling back to inches");
|
||||
unit = GIMP_UNIT_INCH;
|
||||
|
@ -1923,7 +1923,7 @@ xcf_load_image_props (XcfInfo *info,
|
||||
info->cp += xcf_read_int32 (info->fp, &unit, 1);
|
||||
|
||||
if ((unit <= GIMP_UNIT_PIXEL) ||
|
||||
(unit >= gimp_unit_get_number_of_units()))
|
||||
(unit >= gimp_unit_get_number_of_built_in_units()))
|
||||
{
|
||||
g_message ("Warning, unit out of range in XCF file, falling back to inches");
|
||||
unit = GIMP_UNIT_INCH;
|
||||
|
Loading…
Reference in New Issue
Block a user