summaryrefslogtreecommitdiff
path: root/block-cow.c
diff options
context:
space:
mode:
authorblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2009-04-13 16:31:01 +0000
committerblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2009-04-13 16:31:01 +0000
commit3f4cb3d37fb74db3580029624c8acd83dd5f4787 (patch)
tree3c6d13cb27ef0fb8d2ff465ba31d3b4647ec1c27 /block-cow.c
parent14d483eca0eb5f8b58b4b0317b734d485e4ca181 (diff)
downloadqemu-3f4cb3d37fb74db3580029624c8acd83dd5f4787.tar.gz
qemu-3f4cb3d37fb74db3580029624c8acd83dd5f4787.tar.bz2
qemu-3f4cb3d37fb74db3580029624c8acd83dd5f4787.zip
Fix OpenSolaris gcc4 warnings: iovec type mismatches, missing 'static'
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7103 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'block-cow.c')
-rw-r--r--block-cow.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/block-cow.c b/block-cow.c
index b9a1971b17..17e3292258 100644
--- a/block-cow.c
+++ b/block-cow.c
@@ -95,10 +95,10 @@ static int cow_open(BlockDriverState *bs, const char *filename, int flags)
/* mmap the bitmap */
s->cow_bitmap_size = ((bs->total_sectors + 7) >> 3) + sizeof(cow_header);
- s->cow_bitmap_addr = mmap(get_mmap_addr(s->cow_bitmap_size),
- s->cow_bitmap_size,
- PROT_READ | PROT_WRITE,
- MAP_SHARED, s->fd, 0);
+ s->cow_bitmap_addr = (void *)mmap(get_mmap_addr(s->cow_bitmap_size),
+ s->cow_bitmap_size,
+ PROT_READ | PROT_WRITE,
+ MAP_SHARED, s->fd, 0);
if (s->cow_bitmap_addr == MAP_FAILED)
goto fail;
s->cow_bitmap = s->cow_bitmap_addr + sizeof(cow_header);
@@ -197,7 +197,7 @@ static int cow_write(BlockDriverState *bs, int64_t sector_num,
static void cow_close(BlockDriverState *bs)
{
BDRVCowState *s = bs->opaque;
- munmap(s->cow_bitmap_addr, s->cow_bitmap_size);
+ munmap((void *)s->cow_bitmap_addr, s->cow_bitmap_size);
close(s->fd);
}