hardware/intel/common/vaapi
Revisión | 4f8fe64e513ecc461e03e9115315a1459a4684dd (tree) |
---|---|
Tiempo | 2018-11-21 14:34:42 |
Autor | Xu Guangxin <guangxin.xu@inte...> |
Commiter | Xiang, Haihao |
gen75_proc_picture: check return value from gen75_vpp_vebox
gen75_vpp_vebox will check many things like invalid param, unsupported features.
Better check the return value
@@ -327,7 +327,9 @@ gen75_proc_picture(VADriverContextP ctx, | ||
327 | 327 | proc_ctx->surface_render_output_object = stage1_dst_surf; |
328 | 328 | } |
329 | 329 | |
330 | - gen75_vpp_vebox(ctx, proc_ctx); | |
330 | + status = gen75_vpp_vebox(ctx, proc_ctx); | |
331 | + if (status != VA_STATUS_SUCCESS) | |
332 | + goto error; | |
331 | 333 | } |
332 | 334 | |
333 | 335 | if ((vpp_stage3 == 1) && (vpp_stage2 == 1)) { |
@@ -388,7 +390,9 @@ gen75_proc_picture(VADriverContextP ctx, | ||
388 | 390 | filter->type == VAProcFilterSkinToneEnhancement || |
389 | 391 | filter->type == VAProcFilterSharpening || |
390 | 392 | filter->type == VAProcFilterColorBalance) { |
391 | - gen75_vpp_vebox(ctx, proc_ctx); | |
393 | + status = gen75_vpp_vebox(ctx, proc_ctx); | |
394 | + if (status != VA_STATUS_SUCCESS) | |
395 | + goto error; | |
392 | 396 | } |
393 | 397 | } else if (pipeline_param->num_filters >= 2) { |
394 | 398 | unsigned int i = 0; |
@@ -413,7 +417,9 @@ gen75_proc_picture(VADriverContextP ctx, | ||
413 | 417 | assert(0); |
414 | 418 | } |
415 | 419 | } |
416 | - gen75_vpp_vebox(ctx, proc_ctx); | |
420 | + status = gen75_vpp_vebox(ctx, proc_ctx); | |
421 | + if (status != VA_STATUS_SUCCESS) | |
422 | + goto error; | |
417 | 423 | } |
418 | 424 | } |
419 | 425 |
@@ -431,7 +437,9 @@ gen75_proc_picture(VADriverContextP ctx, | ||
431 | 437 | proc_ctx->surface_render_output_object = obj_dst_surf; |
432 | 438 | } |
433 | 439 | |
434 | - gen75_vpp_vebox(ctx, proc_ctx); | |
440 | + status = gen75_vpp_vebox(ctx, proc_ctx); | |
441 | + if (status != VA_STATUS_SUCCESS) | |
442 | + goto error; | |
435 | 443 | } |
436 | 444 | |
437 | 445 | if (num_tmp_surfaces) |