copy_in: stop on read errors
commite6a753026d887652976bdb44227dbe2b31e0914f
authorPetr Tesarik <petr@tesarici.cz>
Fri, 9 Nov 2012 12:24:20 +0000 (9 13:24 +0100)
committerPetr Tesarik <petr@tesarici.cz>
Fri, 9 Nov 2012 12:24:20 +0000 (9 13:24 +0100)
tree2c2c91b10953114bfc83c4030c1bffb364785e72
parent807b409fb1f63ccb114771af1627e9a31dc46436
copy_in: stop on read errors

Read errors result in creating a virtual block with the HED_BLOCK_BAD
flag. copy_in() and consequently hed_file_cpin() would have silently
delivered such a block as all zeroes, so libhed users have no chance
to find out that there was a read error.

Fix this by returning a short count on error.
libhed/file.c