Skip to content
This repository has been archived by the owner on Nov 17, 2020. It is now read-only.

Commit

Permalink
Bug 624968 - div by zero in g_malloc_n family
Browse files Browse the repository at this point in the history
  • Loading branch information
behdad committed Jul 21, 2010
1 parent 5063d78 commit 8f80ff0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion glib/gmem.c
Expand Up @@ -263,7 +263,7 @@ g_try_realloc (gpointer mem,
}


#define SIZE_OVERFLOWS(a,b) (G_UNLIKELY ((a) > G_MAXSIZE / (b)))
#define SIZE_OVERFLOWS(a,b) (G_UNLIKELY ((b) > 0 && (a) > G_MAXSIZE / (b)))

gpointer
g_malloc_n (gsize n_blocks,
Expand Down

0 comments on commit 8f80ff0

Please sign in to comment.