g_return_if_fail() on width, height or bpp <= 0. Doesn't fix anything but

2004-03-25  Michael Natterer  <mitch@gimp.org>

	* app/base/tile-manager.c (tile_manager_new): g_return_if_fail()
	on width, height or bpp <= 0. Doesn't fix anything but badly
	warns (and helps debugging) on bug #138117.
This commit is contained in:
Michael Natterer
2004-03-25 17:58:26 +00:00
committed by Michael Natterer
parent dbe84d2df5
commit d23e1ffe3b
2 changed files with 10 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2004-03-25 Michael Natterer <mitch@gimp.org>
* app/base/tile-manager.c (tile_manager_new): g_return_if_fail()
on width, height or bpp <= 0. Doesn't fix anything but badly
warns (and helps debugging) on bug #138117.
2004-03-25 Michael Natterer <mitch@gimp.org>
* app/tools/gimpvectortool.c (gimp_vector_tool_button_release):

View File

@ -46,6 +46,10 @@ tile_manager_new (gint toplevel_width,
gint width;
gint height;
g_return_val_if_fail (toplevel_width > 0, NULL);
g_return_val_if_fail (toplevel_height > 0, NULL);
g_return_val_if_fail (bpp > 0, NULL);
tm = g_new0 (TileManager, 1);
width = toplevel_width;