static int count_contiguous_clusters_by_type(int nb_clusters,

                                             uint64_t *l2_table,

                                             int wanted_type)

{

    int i;



    for (i = 0; i < nb_clusters; i++) {

        int type = qcow2_get_cluster_type(be64_to_cpu(l2_table[i]));



        if (type != wanted_type) {

            break;

        }

    }



    return i;

}

static int count_contiguous_clusters_by_type(int nb_clusters,

                                             uint64_t *l2_table,

                                             int wanted_type)

{

    int i;



    for (i = 0; i < nb_clusters; i++) {

        int type = qcow2_get_cluster_type(be64_to_cpu(l2_table[i]));



        if (type != wanted_type) {

            break;

        }

    }



    return i;

}

static int FUNC_0(int VAR_0,

                                             uint64_t *VAR_1,

                                             int VAR_2)

{

    int VAR_3;



    for (VAR_3 = 0; VAR_3 < VAR_0; VAR_3++) {

        int VAR_4 = qcow2_get_cluster_type(be64_to_cpu(VAR_1[VAR_3]));



        if (VAR_4 != VAR_2) {

            break;

        }

    }



    return VAR_3;

}

static int FUNC_0(int VAR_0,
uint64_t *VAR_1,
int VAR_2)
{ int VAR_3; for (VAR_3 = 0; VAR_3 < VAR_0; VAR_3++) { int VAR_4 = qcow2_get_cluster_type(be64_to_cpu(VAR_1[VAR_3])); if (VAR_4 != VAR_2) { break; } } return VAR_3; }