gralloc: Fix incorrect handle validation check

The YUV plane info reported to driver has an incorrect handle
check. Use the check correctly.

Change-Id: Ice6388a3d8b91bfa5373e850e3102c6ccf92eb75
This commit is contained in:
Naseer Ahmed
2014-04-30 15:30:39 -04:00
parent 64e1ce83b7
commit f5ff33a0de

View File

@@ -431,7 +431,7 @@ int gralloc_perform(struct gralloc_module_t const* module,
{ {
private_handle_t* hnd = va_arg(args, private_handle_t*); private_handle_t* hnd = va_arg(args, private_handle_t*);
android_ycbcr* ycbcr = va_arg(args, struct android_ycbcr *); android_ycbcr* ycbcr = va_arg(args, struct android_ycbcr *);
if (private_handle_t::validate(hnd)) { if (!private_handle_t::validate(hnd)) {
res = getYUVPlaneInfo(hnd, ycbcr); res = getYUVPlaneInfo(hnd, ycbcr);
} }
} break; } break;