static int find_snapshot_by_id(BlockDriverState *bs, const char *id_str)

{

    BDRVQcowState *s = bs->opaque;

    int i;



    for(i = 0; i < s->nb_snapshots; i++) {

        if (!strcmp(s->snapshots[i].id_str, id_str))

            return i;

    }

    return -1;

}

static int find_snapshot_by_id(BlockDriverState *bs, const char *id_str)

{

    BDRVQcowState *s = bs->opaque;

    int i;



    for(i = 0; i < s->nb_snapshots; i++) {

        if (!strcmp(s->snapshots[i].id_str, id_str))

            return i;

    }

    return -1;

}

static int find_snapshot_by_id(BlockDriverState *bs, const char *id_str)     for(i = 0; i < s->nb_snapshots; i++) {         if (!strcmp(s->snapshots[i].id_str, id_str))             return i;     BDRVQcowState *s = bs->opaque;     for(i = 0; i < s->nb_snapshots; i++) {             return i;     return -1;
static int FUNC_0(BlockDriverState *VAR_0, const char *VAR_1)

{

    BDRVQcowState *s = VAR_0->opaque;

    int VAR_2;



    for(VAR_2 = 0; VAR_2 < s->nb_snapshots; VAR_2++) {

        if (!strcmp(s->snapshots[VAR_2].VAR_1, VAR_1))

            return VAR_2;

    }

    return -1;

}

static int FUNC_0(BlockDriverState *VAR_0, const char *VAR_1)
{ BDRVQcowState *s = VAR_0->opaque; int VAR_2; for(VAR_2 = 0; VAR_2 < s->nb_snapshots; VAR_2++) { if (!strcmp(s->snapshots[VAR_2].VAR_1, VAR_1))
return VAR_2; } return -1; }