[fdio] Rationalize default handling for null read/write
Previously, the default behavior for read was to succeed at reading zero bytes and the default behavior for write was to succeed at writing all the bytes (even though nothing actually happened in either case). After this CL, these operations fail by default and the exact failure behavior is consistent between fdio and zxio. Test: null-test Change-Id: I22587be52de3571ccefd25f21ec20180b3380cf1
Showing
- system/ulib/fdio/null.c 12 additions, 4 deletionssystem/ulib/fdio/null.c
- system/ulib/fdio/zxio.c 2 additions, 5 deletionssystem/ulib/fdio/zxio.c
- system/ulib/zxio/include/lib/zxio/inception.h 0 additions, 4 deletionssystem/ulib/zxio/include/lib/zxio/inception.h
- system/ulib/zxio/include/lib/zxio/null.h 99 additions, 63 deletionssystem/ulib/zxio/include/lib/zxio/null.h
- system/ulib/zxio/null.cpp 50 additions, 31 deletionssystem/ulib/zxio/null.cpp
- system/ulib/zxio/pipe.cpp 11 additions, 27 deletionssystem/ulib/zxio/pipe.cpp
- system/ulib/zxio/remote.cpp 26 additions, 27 deletionssystem/ulib/zxio/remote.cpp
- system/ulib/zxio/vmofile.cpp 11 additions, 27 deletionssystem/ulib/zxio/vmofile.cpp
- system/utest/chromeos-disk-setup/chromeos-disk-setup.cpp 6 additions, 5 deletionssystem/utest/chromeos-disk-setup/chromeos-disk-setup.cpp
- system/utest/zxio/null-test.cpp 11 additions, 7 deletionssystem/utest/zxio/null-test.cpp
- system/utest/zxio/vmofile-test.cpp 2 additions, 2 deletionssystem/utest/zxio/vmofile-test.cpp
Loading
Please register or sign in to comment