Fix incorrect access mode check
authorChengwei Yang <chengwei.yang@intel.com>
Mon, 5 Nov 2012 04:25:41 +0000 (12:25 +0800)
committerChengwei Yang <chengwei.yang@intel.com>
Mon, 5 Nov 2012 04:27:49 +0000 (12:27 +0800)
commit4dc36c99cdfdad3463b94d2bd943208c17220db9
treed834a048b291125826a24c9f01d31c8ab0989742
parentf7271758e7ec7eb01ef190e34a00e7930ea6534f
Fix incorrect access mode check

The O_* variales are integers and aren't not suitable with bit
operation, because O_RDONLY is 0, so if the mode is O_RDONLY, (mode &
O_RDONLY) always return false. So the access mode is always 0,
that means F_OK rather than R_OK.

Change-Id: If750f85864d32f7d0a039b2ee114ef133a311434
Signed-off-by: Chengwei Yang <chengwei.yang@intel.com>
logutil.c