mirror of https://github.com/GNOME/gimp.git
fixed range check of blur type parameter (bug #142965).
2004-05-24 Sven Neumann <sven@gimp.org> * plug-ins/common/mblur.c: fixed range check of blur type parameter (bug #142965).
This commit is contained in:
parent
1c860eb121
commit
673939f21b
|
@ -1,3 +1,8 @@
|
|||
2004-05-24 Sven Neumann <sven@gimp.org>
|
||||
|
||||
* plug-ins/common/mblur.c: fixed range check of blur type
|
||||
parameter (bug #142965).
|
||||
|
||||
2004-05-24 Sven Neumann <sven@gimp.org>
|
||||
|
||||
* plug-ins/maze/maze_face.c: fixed a compiler warning.
|
||||
|
|
|
@ -65,11 +65,14 @@
|
|||
#define PLUG_IN_VERSION "Sep 1997, 1.2"
|
||||
#define HELP_ID "plug-in-mblur"
|
||||
|
||||
#define MBLUR_LINEAR 0
|
||||
#define MBLUR_RADIAL 1
|
||||
#define MBLUR_ZOOM 2
|
||||
typedef enum
|
||||
{
|
||||
MBLUR_LINEAR,
|
||||
MBLUR_RADIAL,
|
||||
MBLUR_ZOOM,
|
||||
MBLUR_MAX = MBLUR_ZOOM
|
||||
} MBlurType;
|
||||
|
||||
#define MBLUR_MAX MBLUR_ZOOM
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
@ -221,7 +224,7 @@ run (const gchar *name,
|
|||
mbvals.angle = param[5].data.d_int32;
|
||||
}
|
||||
|
||||
if ((mbvals.mblur_type < 0) && (mbvals.mblur_type > MBLUR_ZOOM))
|
||||
if ((mbvals.mblur_type < 0) || (mbvals.mblur_type > MBLUR_MAX))
|
||||
status= GIMP_PDB_CALLING_ERROR;
|
||||
break;
|
||||
|
||||
|
|
Loading…
Reference in New Issue