mirror of https://github.com/xemu-project/xemu.git
Cleanup qemu-nbd related code, by Laurent Vivier.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4829 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
96935aa4e3
commit
975b092bd9
4
nbd.c
4
nbd.c
|
@ -388,8 +388,8 @@ int nbd_trip(BlockDriverState *bs, int csock, off_t size, uint64_t dev_offset, o
|
||||||
}
|
}
|
||||||
|
|
||||||
if (len > sizeof(data)) {
|
if (len > sizeof(data)) {
|
||||||
LOG("len (%u) is larger than max len (%u)",
|
LOG("len (%u) is larger than max len (%lu)",
|
||||||
len, sizeof(data));
|
len, (unsigned long)sizeof(data));
|
||||||
errno = EINVAL;
|
errno = EINVAL;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1318,6 +1318,7 @@ snapshots.
|
||||||
* disk_images_snapshot_mode:: Snapshot mode
|
* disk_images_snapshot_mode:: Snapshot mode
|
||||||
* vm_snapshots:: VM snapshots
|
* vm_snapshots:: VM snapshots
|
||||||
* qemu_img_invocation:: qemu-img Invocation
|
* qemu_img_invocation:: qemu-img Invocation
|
||||||
|
* qemu_nbd_invocation:: qemu-nbd Invocation
|
||||||
* host_drives:: Using host drives
|
* host_drives:: Using host drives
|
||||||
* disk_images_fat_images:: Virtual FAT disk images
|
* disk_images_fat_images:: Virtual FAT disk images
|
||||||
@end menu
|
@end menu
|
||||||
|
@ -1400,6 +1401,11 @@ state is not saved or restored properly (in particular USB).
|
||||||
|
|
||||||
@include qemu-img.texi
|
@include qemu-img.texi
|
||||||
|
|
||||||
|
@node qemu_nbd_invocation
|
||||||
|
@subsection @code{qemu-nbd} Invocation
|
||||||
|
|
||||||
|
@include qemu-nbd.texi
|
||||||
|
|
||||||
@node host_drives
|
@node host_drives
|
||||||
@subsection Using host drives
|
@subsection Using host drives
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,6 @@
|
||||||
#include "block_int.h"
|
#include "block_int.h"
|
||||||
#include "nbd.h"
|
#include "nbd.h"
|
||||||
|
|
||||||
#include <malloc.h>
|
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <getopt.h>
|
#include <getopt.h>
|
||||||
|
@ -168,6 +167,7 @@ int main(int argc, char **argv)
|
||||||
{ "partition", 1, 0, 'P' },
|
{ "partition", 1, 0, 'P' },
|
||||||
{ "snapshot", 0, 0, 's' },
|
{ "snapshot", 0, 0, 's' },
|
||||||
{ "verbose", 0, 0, 'v' },
|
{ "verbose", 0, 0, 'v' },
|
||||||
|
{ NULL, 0, 0, 0 }
|
||||||
};
|
};
|
||||||
int ch;
|
int ch;
|
||||||
int opt_ind = 0;
|
int opt_ind = 0;
|
||||||
|
|
Loading…
Reference in New Issue