Instead of having unlink() calls in the generic block layer, where we
aren't even guarateed to have a file name, move them to those block
drivers that are actually used and that always have a filename. Gets us
rid of some #ifdefs as well.
The patch also converts bs->is_temporary to a new BDRV_O_TEMPORARY open
flag so that it is inherited in the protocol layer and the raw-posix and
raw-win32 drivers can unlink the file.
Signed-off-by: Kevin Wolf <address@hidden>
---
block.c | 36 ++++++++++--------------------------
block/raw-posix.c | 5 ++++-
block/raw-win32.c | 3 +++
include/block/block.h | 1 +
include/block/block_int.h | 1 -
5 files changed, 18 insertions(+), 28 deletions(-)