diff options
author | Campbell Barton <campbell@blender.org> | 2022-10-12 02:33:53 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-10-12 02:39:12 +0300 |
commit | b9e4d930b389e8e36599766fe9d1486d8cd9b8cb (patch) | |
tree | 83e4ec76a1dda737a2c80c3d3fbe4e45a54bc824 | |
parent | 3f64b886847ac3384bd4303a5c689b486d878636 (diff) |
Cleanup: use 'u' prefixed unsigned types
-rw-r--r-- | intern/ghost/intern/GHOST_SystemX11.cpp | 4 | ||||
-rw-r--r-- | intern/guardedalloc/intern/mallocn.c | 2 | ||||
-rw-r--r-- | intern/guardedalloc/intern/mallocn_lockfree_impl.c | 10 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/cloth.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/subdiv_ccg.cc | 2 | ||||
-rw-r--r-- | source/blender/ikplugin/intern/itasc_plugin.cpp | 2 |
6 files changed, 11 insertions, 11 deletions
diff --git a/intern/ghost/intern/GHOST_SystemX11.cpp b/intern/ghost/intern/GHOST_SystemX11.cpp index 6b468f041c1..4523f6fa37c 100644 --- a/intern/ghost/intern/GHOST_SystemX11.cpp +++ b/intern/ghost/intern/GHOST_SystemX11.cpp @@ -2435,11 +2435,11 @@ GHOST_TSuccess GHOST_SystemX11::showMessageBox(const char *title, utf8Str, 8, PropModeReplace, - (const unsigned char *)title, + (const uchar *)title, int(strlen(title))); XChangeProperty( - m_display, window, winType, XA_ATOM, 32, PropModeReplace, (unsigned char *)&typeDialog, 1); + m_display, window, winType, XA_ATOM, 32, PropModeReplace, (uchar *)&typeDialog, 1); } /* Create buttons GC */ diff --git a/intern/guardedalloc/intern/mallocn.c b/intern/guardedalloc/intern/mallocn.c index 63f06ced31d..984e641e7c1 100644 --- a/intern/guardedalloc/intern/mallocn.c +++ b/intern/guardedalloc/intern/mallocn.c @@ -43,7 +43,7 @@ void (*MEM_set_error_callback)(void (*func)(const char *)) = MEM_lockfree_set_er bool (*MEM_consistency_check)(void) = MEM_lockfree_consistency_check; void (*MEM_set_memory_debug)(void) = MEM_lockfree_set_memory_debug; size_t (*MEM_get_memory_in_use)(void) = MEM_lockfree_get_memory_in_use; -unsigned int (*MEM_get_memory_blocks_in_use)(void) = MEM_lockfree_get_memory_blocks_in_use; +uint (*MEM_get_memory_blocks_in_use)(void) = MEM_lockfree_get_memory_blocks_in_use; void (*MEM_reset_peak_memory)(void) = MEM_lockfree_reset_peak_memory; size_t (*MEM_get_peak_memory)(void) = MEM_lockfree_get_peak_memory; diff --git a/intern/guardedalloc/intern/mallocn_lockfree_impl.c b/intern/guardedalloc/intern/mallocn_lockfree_impl.c index b5ee539ff4d..5a969186b19 100644 --- a/intern/guardedalloc/intern/mallocn_lockfree_impl.c +++ b/intern/guardedalloc/intern/mallocn_lockfree_impl.c @@ -233,7 +233,7 @@ void *MEM_lockfree_callocN(size_t len, const char *str) print_error("Calloc returns null: len=" SIZET_FORMAT " in %s, total %u\n", SIZET_ARG(len), str, - (unsigned int)mem_in_use); + (uint)mem_in_use); return NULL; } @@ -278,7 +278,7 @@ void *MEM_lockfree_mallocN(size_t len, const char *str) print_error("Malloc returns null: len=" SIZET_FORMAT " in %s, total %u\n", SIZET_ARG(len), str, - (unsigned int)mem_in_use); + (uint)mem_in_use); return NULL; } @@ -292,7 +292,7 @@ void *MEM_lockfree_malloc_arrayN(size_t len, size_t size, const char *str) SIZET_ARG(len), SIZET_ARG(size), str, - (unsigned int)mem_in_use); + (uint)mem_in_use); abort(); return NULL; } @@ -349,7 +349,7 @@ void *MEM_lockfree_mallocN_aligned(size_t len, size_t alignment, const char *str print_error("Malloc returns null: len=" SIZET_FORMAT " in %s, total %u\n", SIZET_ARG(len), str, - (unsigned int)mem_in_use); + (uint)mem_in_use); return NULL; } @@ -401,7 +401,7 @@ size_t MEM_lockfree_get_memory_in_use(void) return mem_in_use; } -unsigned int MEM_lockfree_get_memory_blocks_in_use(void) +uint MEM_lockfree_get_memory_blocks_in_use(void) { return totblock; } diff --git a/source/blender/blenkernel/intern/cloth.c b/source/blender/blenkernel/intern/cloth.c index 56de583e2db..7ee6b4cdfc0 100644 --- a/source/blender/blenkernel/intern/cloth.c +++ b/source/blender/blenkernel/intern/cloth.c @@ -1167,7 +1167,7 @@ static Mesh *cloth_make_rest_mesh(ClothModifierData *clmd, Mesh *mesh) MVert *mvert = BKE_mesh_verts_for_write(mesh); /* vertex count is already ensured to match */ - for (unsigned i = 0; i < mesh->totvert; i++, verts++) { + for (uint i = 0; i < mesh->totvert; i++, verts++) { copy_v3_v3(mvert[i].co, verts->xrest); } BKE_mesh_tag_coords_changed(new_mesh); diff --git a/source/blender/blenkernel/intern/subdiv_ccg.cc b/source/blender/blenkernel/intern/subdiv_ccg.cc index feee7ac0f0f..8ccf2c9cec5 100644 --- a/source/blender/blenkernel/intern/subdiv_ccg.cc +++ b/source/blender/blenkernel/intern/subdiv_ccg.cc @@ -128,7 +128,7 @@ static void subdiv_ccg_alloc_elements(SubdivCCG *subdiv_ccg, Subdiv *subdiv) subdiv_ccg->num_grids = num_grids; subdiv_ccg->grids = static_cast<CCGElem **>( MEM_calloc_arrayN(num_grids, sizeof(CCGElem *), "subdiv ccg grids")); - subdiv_ccg->grids_storage = static_cast<unsigned char *>( + subdiv_ccg->grids_storage = static_cast<uchar *>( MEM_calloc_arrayN(num_grids, size_t(grid_area) * element_size, "subdiv ccg grids storage")); const size_t grid_size_in_bytes = size_t(grid_area) * element_size; for (int grid_index = 0; grid_index < num_grids; grid_index++) { diff --git a/source/blender/ikplugin/intern/itasc_plugin.cpp b/source/blender/ikplugin/intern/itasc_plugin.cpp index 78fb75ddb40..9317f14b7f1 100644 --- a/source/blender/ikplugin/intern/itasc_plugin.cpp +++ b/source/blender/ikplugin/intern/itasc_plugin.cpp @@ -1783,7 +1783,7 @@ static void execute_scene(struct Depsgraph *depsgraph, for (i = ikscene->targets.size(); i > 0; i--) { IK_Target *iktarget = ikscene->targets[i - 1]; if (!(iktarget->blenderConstraint->flag & CONSTRAINT_OFF) && iktarget->constraint) { - unsigned int nvalues; + uint nvalues; const iTaSC::ConstraintValues *values; values = iktarget->constraint->getControlParameters(&nvalues); iktarget->errorCallback(values, nvalues, iktarget); |