using signed return value for read()