mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2024-12-29 11:06:18 +00:00
aux/util: clang-tidy
This commit is contained in:
parent
876bd5088f
commit
86d3d2b149
|
@ -55,9 +55,8 @@ u_hashmap_int_find(struct u_hashmap_int *hmi, uint64_t key, void **out_item)
|
|||
if (search != hmi->map.end()) {
|
||||
*out_item = search->second;
|
||||
return 0;
|
||||
} else {
|
||||
return -1;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
extern "C" int
|
||||
|
|
|
@ -30,16 +30,16 @@ int
|
|||
u_hashmap_int_create(struct u_hashmap_int **out_hashmap);
|
||||
|
||||
int
|
||||
u_hashmap_int_destroy(struct u_hashmap_int **hs);
|
||||
u_hashmap_int_destroy(struct u_hashmap_int **hmi);
|
||||
|
||||
int
|
||||
u_hashmap_int_find(struct u_hashmap_int *hs, uint64_t key, void **out_item);
|
||||
u_hashmap_int_find(struct u_hashmap_int *hmi, uint64_t key, void **out_item);
|
||||
|
||||
int
|
||||
u_hashmap_int_insert(struct u_hashmap_int *hs, uint64_t key, void *value);
|
||||
u_hashmap_int_insert(struct u_hashmap_int *hmi, uint64_t key, void *value);
|
||||
|
||||
int
|
||||
u_hashmap_int_erase(struct u_hashmap_int *hs, uint64_t key);
|
||||
u_hashmap_int_erase(struct u_hashmap_int *hmi, uint64_t key);
|
||||
|
||||
/*!
|
||||
* First clear the hashmap and then call the given callback with each item that
|
||||
|
@ -48,7 +48,7 @@ u_hashmap_int_erase(struct u_hashmap_int *hs, uint64_t key);
|
|||
* @ingroup aux_util
|
||||
*/
|
||||
void
|
||||
u_hashmap_int_clear_and_call_for_each(struct u_hashmap_int *hs,
|
||||
u_hashmap_int_clear_and_call_for_each(struct u_hashmap_int *hmi,
|
||||
u_hashmap_int_callback cb,
|
||||
void *priv);
|
||||
|
||||
|
|
|
@ -60,9 +60,8 @@ u_hashset_find_str(struct u_hashset *hs,
|
|||
if (search != hs->map.end()) {
|
||||
*out_item = search->second;
|
||||
return 0;
|
||||
} else {
|
||||
return -1;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
extern "C" int
|
||||
|
|
|
@ -52,11 +52,11 @@ clamp_to_byte(int v)
|
|||
{
|
||||
if (v < 0) {
|
||||
return 0;
|
||||
} else if (v >= 255) {
|
||||
return 255;
|
||||
} else {
|
||||
return v;
|
||||
}
|
||||
if (v >= 255) {
|
||||
return 255;
|
||||
}
|
||||
return v;
|
||||
}
|
||||
|
||||
static inline uint32_t
|
||||
|
@ -73,7 +73,7 @@ YUV444_to_RGBX8888(int y, int u, int v)
|
|||
return B << 16 | G << 8 | R;
|
||||
}
|
||||
|
||||
static uint32_t lookup_YUV_to_RGBX[256][256][256] = {0};
|
||||
static uint32_t lookup_YUV_to_RGBX[256][256][256] = {{0}};
|
||||
|
||||
static void
|
||||
generate_lookup_YUV_to_RGBX()
|
||||
|
|
Loading…
Reference in a new issue