ir: attributes: fix index and count integer types
[babeltrace.git] / lib / ctf-ir / attributes.c
index c6e8a232e885bc0c35fd08de3848a18ee87d6a3f..b354951090de8fd0318bee31e23cfa1717258751 100644 (file)
@@ -58,14 +58,14 @@ void bt_ctf_attributes_destroy(struct bt_value *attr_obj)
 }
 
 BT_HIDDEN
-int bt_ctf_attributes_get_count(struct bt_value *attr_obj)
+int64_t bt_ctf_attributes_get_count(struct bt_value *attr_obj)
 {
        return bt_value_array_size(attr_obj);
 }
 
 BT_HIDDEN
 const char *bt_ctf_attributes_get_field_name(struct bt_value *attr_obj,
-               int index)
+               uint64_t index)
 {
        int rc;
        const char *ret = NULL;
@@ -103,7 +103,7 @@ end:
 
 BT_HIDDEN
 struct bt_value *bt_ctf_attributes_get_field_value(struct bt_value *attr_obj,
-               int index)
+               uint64_t index)
 {
        struct bt_value *value_obj = NULL;
        struct bt_value *attr_field_obj = NULL;
@@ -130,8 +130,8 @@ static
 struct bt_value *bt_ctf_attributes_get_field_by_name(
                struct bt_value *attr_obj, const char *name)
 {
-       int i;
-       int attr_size;
+       uint64_t i;
+       int64_t attr_size;
        struct bt_value *value_obj = NULL;
        struct bt_value *attr_field_name_obj = NULL;
 
@@ -251,8 +251,8 @@ end:
 BT_HIDDEN
 int bt_ctf_attributes_freeze(struct bt_value *attr_obj)
 {
-       int i;
-       int count;
+       uint64_t i;
+       int64_t count;
        int ret = 0;
 
        if (!attr_obj) {
This page took 0.025337 seconds and 4 git commands to generate.