qemu/include/block
Jeff Cody 9a29e18f7d block: update string sizes for filename,backing_file,exact_filename
The string field entries 'filename', 'backing_file', and
'exact_filename' in the BlockDriverState struct are defined as 1024
bytes.

However, many places that use these values accept a maximum of PATH_MAX
bytes, so we have a mixture of 1024 byte and PATH_MAX byte allocations.
This patch makes the BlockDriverStruct field string sizes match usage.

This patch also does a few fixes related to the size that needs to
happen now:

    * the block qapi driver is updated to use PATH_MAX bytes
    * the qcow and qcow2 drivers have an additional safety check
    * the block vvfat driver is updated to use PATH_MAX bytes
      for the size of backing_file, for systems where PATH_MAX is < 1024
      bytes.
    * qemu-img uses PATH_MAX rather than 1024.  These instances were not
      changed to be dynamically allocated, however, as the extra
      temporary 3K in stack usage for qemu-img does not seem worrisome.

Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: John Snow <jsnow@redhat.com>
Signed-off-by: Jeff Cody <jcody@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2015-01-23 18:17:06 +01:00
..
accounting.h block: Make the block accounting functions operate on BlockAcctStats 2014-09-10 10:41:29 +02:00
aio.h qemu-timer: rename timer_init to timer_init_tl 2015-01-14 10:38:57 +01:00
block_int.h block: update string sizes for filename,backing_file,exact_filename 2015-01-23 18:17:06 +01:00
block.h block: Split BLOCK_OP_TYPE_COMMIT to BLOCK_OP_TYPE_COMMIT_{SOURCE, TARGET} 2015-01-13 13:43:29 +00:00
blockjob.h blockjob: add block_job_defer_to_main_loop() 2014-11-03 11:41:49 +00:00
coroutine_int.h coroutine: stop using AioContext in CoQueue 2013-05-24 16:17:56 +02:00
coroutine.h coroutine: drop qemu_coroutine_adjust_pool_size 2015-01-13 13:43:29 +00:00
nbd.h nbd: Change external interface to BlockBackend 2014-12-10 10:31:12 +01:00
qapi.h block/qapi: Convert qmp_query_block() to BlockBackend 2014-10-20 14:03:50 +02:00
scsi.h scsi: Print command name in debug 2014-06-18 08:47:10 +02:00
snapshot.h qemu-nbd: support internal snapshot export 2013-12-04 15:19:00 +01:00
thread-pool.h block: Rename BlockDriverCompletionFunc to BlockCompletionFunc 2014-10-20 13:41:27 +02:00