|
If read() fails, it returns -1.
It will generate unpredictable result when compare -1 and sizeof()'s
size_t(unsigned) value.
By the way, cast “ssize_t” to “size_t” to slience the warning.
Bug-AGL:SPEC-2422
Change-Id: Ib56c1ebbcaaac48600a6747d5cc013c407dc14dd
Signed-off-by: Li Xiaoming <lixm.fnst@cn.fujitsu.com>
|