Skip to content

Commit 1e70105

Browse files
dschogitster
authored andcommitted
nedmalloc: fix misleading indentation
Some code in nedmalloc is indented in a funny way that could be misinterpreted as if a line after a for loop was included in the loop body, when it is not. GCC 6 complains about this in DEVELOPER=YepSure mode. Signed-off-by: Johannes Schindelin <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 08df31e commit 1e70105

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

compat/nedmalloc/nedmalloc.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -938,10 +938,10 @@ void **nedpindependent_comalloc(nedpool *p, size_t elems, size_t *sizes, void **
938938
void **ret;
939939
threadcache *tc;
940940
int mymspace;
941-
size_t i, *adjustedsizes=(size_t *) alloca(elems*sizeof(size_t));
942-
if(!adjustedsizes) return 0;
943-
for(i=0; i<elems; i++)
944-
adjustedsizes[i]=sizes[i]<sizeof(threadcacheblk) ? sizeof(threadcacheblk) : sizes[i];
941+
size_t i, *adjustedsizes=(size_t *) alloca(elems*sizeof(size_t));
942+
if(!adjustedsizes) return 0;
943+
for(i=0; i<elems; i++)
944+
adjustedsizes[i]=sizes[i]<sizeof(threadcacheblk) ? sizeof(threadcacheblk) : sizes[i];
945945
GetThreadCache(&p, &tc, &mymspace, 0);
946946
GETMSPACE(m, p, tc, mymspace, 0,
947947
ret=mspace_independent_comalloc(m, elems, adjustedsizes, chunks));

0 commit comments

Comments
 (0)