fix warnings in evas filter plus a memleak in _vflip_cpu()

This commit is contained in:
Carsten Haitzler 2014-02-08 12:15:35 +09:00
parent 3fe36441ef
commit 078099d63d
3 changed files with 5 additions and 4 deletions

View File

@ -803,7 +803,7 @@ evas_filter_command_blur_add(Evas_Filter_Context *ctx, void *drawctx,
int inbuf, int outbuf, Evas_Filter_Blur_Type type,
int dx, int dy, int ox, int oy)
{
Evas_Filter_Command *cmd;
Evas_Filter_Command *cmd = NULL;
Evas_Filter_Buffer *in = NULL, *out = NULL, *tmp = NULL, *in_dy = NULL;
Evas_Filter_Buffer *out_dy = NULL, *out_dx = NULL;
Evas_Filter_Buffer *copybuf = NULL, *blur_out = NULL;
@ -951,6 +951,7 @@ evas_filter_command_blur_add(Evas_Filter_Context *ctx, void *drawctx,
if (copy_back)
{
if (!cmd) goto fail;
INF("Add copy %d -> %d", copybuf->id, blur_out->id);
cmd->ENFN->context_color_set(cmd->ENDT, drawctx, 0, 0, 0, 255);
id = evas_filter_command_blend_add(ctx, drawctx, copybuf->id, blur_out->id, ox, oy, EVAS_FILTER_FILL_MODE_NONE);

View File

@ -1683,7 +1683,7 @@ _instr2cmd_curve(Evas_Filter_Context *ctx, Evas_Filter_Program *pgm,
const char *src, *dst, *points_str, *interpolation, *channel_name;
DATA8 values[256] = {0}, points[512];
int cmdid, point_count = 0;
char *token, *copy, *saveptr;
char *token, *copy = NULL, *saveptr;
Buffer *in, *out;
Eina_Bool parse_ok = EINA_FALSE;

View File

@ -4,7 +4,7 @@ static Eina_Bool
_vflip_cpu(Evas_Filter_Command *cmd)
{
size_t datasize, stride;
DATA8 *in, *out, *span;
DATA8 *in, *out, *span = NULL;
int w, h, sy, dy, oy, center, t, b, objh;
int s0, s1, d0, d1;
@ -66,7 +66,7 @@ _vflip_cpu(Evas_Filter_Command *cmd)
else
memcpy(dst, src, stride);
}
free(span);
return EINA_TRUE;
}