A
Adnan Abbas
Hi,
I have a test app that writes to a device in raw initiated mode
(RedHat 2.4)
I use open() with O_SYNC flag
I call write() in a loop.
I call fdatasync(fd) in each loop (check for success status)
I call close()
in above test app if i unplug my device during the while loop and
reconnect it, all my data is lost i don't see anything written to the
disk. leads me to believe fdatasync() does not work as expected.
ps(in windows commit() function works fine. and data is actually
written to the disk)
please let me know if there is a way to get the expected result.
Thanks
Adnan Abbas
I have a test app that writes to a device in raw initiated mode
(RedHat 2.4)
I use open() with O_SYNC flag
I call write() in a loop.
I call fdatasync(fd) in each loop (check for success status)
I call close()
in above test app if i unplug my device during the while loop and
reconnect it, all my data is lost i don't see anything written to the
disk. leads me to believe fdatasync() does not work as expected.
ps(in windows commit() function works fine. and data is actually
written to the disk)
please let me know if there is a way to get the expected result.
Thanks
Adnan Abbas