static int rewrite_footer(BlockDriverState* bs)

{

    int ret;

    BDRVVPCState *s = bs->opaque;

    int64_t offset = s->free_data_block_offset;



    ret = bdrv_pwrite(bs->file, offset, s->footer_buf, HEADER_SIZE);

    if (ret < 0)

        return ret;



    return 0;

}

static int rewrite_footer(BlockDriverState* bs)

{

    int ret;

    BDRVVPCState *s = bs->opaque;

    int64_t offset = s->free_data_block_offset;



    ret = bdrv_pwrite(bs->file, offset, s->footer_buf, HEADER_SIZE);

    if (ret < 0)

        return ret;



    return 0;

}

    ret = bdrv_pwrite(bs->file, offset, s->footer_buf, HEADER_SIZE);
static int FUNC_0(BlockDriverState* VAR_0)

{

    int VAR_1;

    BDRVVPCState *s = VAR_0->opaque;

    int64_t offset = s->free_data_block_offset;



    VAR_1 = bdrv_pwrite(VAR_0->file, offset, s->footer_buf, HEADER_SIZE);

    if (VAR_1 < 0)

        return VAR_1;



    return 0;

}

static int FUNC_0(BlockDriverState* VAR_0)
{ int VAR_1; BDRVVPCState *s = VAR_0->opaque; int64_t offset = s->free_data_block_offset; VAR_1 = bdrv_pwrite(VAR_0->file, offset, s->footer_buf, HEADER_SIZE); if (VAR_1 < 0)
return VAR_1; return 0; }