dmabuf: fix checking mmap flags
authorMichael Olbrich <m.olbrich@pengutronix.de>
Tue, 20 May 2014 10:28:15 +0000 (12:28 +0200)
committerNicolas Dufresne <nicolas.dufresne@collabora.co.uk>
Wed, 4 Jun 2014 14:01:27 +0000 (10:01 -0400)
commit42623c995e97a4eda3ca641b37584a4f66f9e095
treee3ebdfd3eb7f52b5894dd4dfd62ec524efcc0691
parentb444d8ba9799ad613359f2b8997ea77f93fa6424
dmabuf: fix checking mmap flags

A simple '&' is not sufficiant. With mmapping_flags == PROT_READ and
prot == PROT_READ|PROT_WRITE the check produces the wrong result.
Change the check to make sure that prot is a subset of mmapping_flags.

https://bugzilla.gnome.org/show_bug.cgi?id=730559
gst-libs/gst/allocators/gstdmabuf.c