the errno settings was fixed but the return value was still being clobbered ... fix that too
the errno settings was fixed but the return value was still being clobbered ... fix that too

joel-porquet/tsar-uclibc,joel-porquet/tsar-uclibc,joel-porquet/tsar-uclibc,joel-porquet/tsar-uclibc