fix more compiler warnings for not checking
pwrite return value.