gimp r26723 - in trunk: . app/pdb tools/pdbgen/pdb
- From: larsc svn gnome org
- To: svn-commits-list gnome org
- Subject: gimp r26723 - in trunk: . app/pdb tools/pdbgen/pdb
- Date: Sat, 23 Aug 2008 12:51:10 +0000 (UTC)
Author: larsc
Date: Sat Aug 23 12:51:10 2008
New Revision: 26723
URL: http://svn.gnome.org/viewvc/gimp?rev=26723&view=rev
Log:
2008-08-23 Lars-Peter Clausen <lars metafoo de>
* tools/pdbgen/pdb/gradient.pdb
(gimp_gradient_segment_range_blend_(colors|opacity)): Don't crash
if the index of the last segment is out of range.
* app/pdb/gradient-cmds.c: regenerated.
Modified:
trunk/ChangeLog
trunk/app/pdb/gradient-cmds.c
trunk/tools/pdbgen/pdb/gradient.pdb
Modified: trunk/app/pdb/gradient-cmds.c
==============================================================================
--- trunk/app/pdb/gradient-cmds.c (original)
+++ trunk/app/pdb/gradient-cmds.c Sat Aug 23 12:51:10 2008
@@ -1304,7 +1304,10 @@
if (start_seg)
{
- gimp_gradient_segment_range_blend (gradient,
+ if (!end_seg)
+ end_seg = gimp_gradient_segment_get_last (start_seg);
+
+ gimp_gradient_segment_range_blend (gradient,
start_seg, end_seg,
&start_seg->left_color,
&end_seg->right_color,
@@ -1346,6 +1349,9 @@
if (start_seg)
{
+ if (!end_seg)
+ end_seg = gimp_gradient_segment_get_last (start_seg);
+
gimp_gradient_segment_range_blend (gradient,
start_seg, end_seg,
&start_seg->left_color,
Modified: trunk/tools/pdbgen/pdb/gradient.pdb
==============================================================================
--- trunk/tools/pdbgen/pdb/gradient.pdb (original)
+++ trunk/tools/pdbgen/pdb/gradient.pdb Sat Aug 23 12:51:10 2008
@@ -1252,7 +1252,10 @@
if (start_seg)
{
- gimp_gradient_segment_range_blend (gradient,
+ if (!end_seg)
+ end_seg = gimp_gradient_segment_get_last (start_seg);
+
+ gimp_gradient_segment_range_blend (gradient,
start_seg, end_seg,
&start_seg->left_color,
&end_seg->right_color,
@@ -1298,6 +1301,9 @@
if (start_seg)
{
+ if (!end_seg)
+ end_seg = gimp_gradient_segment_get_last (start_seg);
+
gimp_gradient_segment_range_blend (gradient,
start_seg, end_seg,
&start_seg->left_color,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]