Commit 82a4dddf authored by Matthias Clasen's avatar Matthias Clasen

Avoid a possible division by zero. (#77820)

	* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
	division by zero.  (#77820)
parent c09a9a9f
2002-04-25 Matthias Clasen <maclas@gmx.de>
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
division by zero. (#77820)
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
......
2002-04-25 Matthias Clasen <maclas@gmx.de>
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
division by zero. (#77820)
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
......
2002-04-25 Matthias Clasen <maclas@gmx.de>
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
division by zero. (#77820)
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
......
2002-04-25 Matthias Clasen <maclas@gmx.de>
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
division by zero. (#77820)
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
......
2002-04-25 Matthias Clasen <maclas@gmx.de>
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
division by zero. (#77820)
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
......
2002-04-25 Matthias Clasen <maclas@gmx.de>
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
division by zero. (#77820)
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
......
......@@ -2041,8 +2041,12 @@ gtk_range_calc_layout (GtkRange *range,
/* slider height is the fraction (page_size /
* total_adjustment_range) times the trough height in pixels
*/
height = ((bottom - top) * (range->adjustment->page_size /
(range->adjustment->upper - range->adjustment->lower)));
if (range->adjustment->upper - range->adjustment->lower != 0)
height = ((bottom - top) * (range->adjustment->page_size /
(range->adjustment->upper - range->adjustment->lower)));
else
height = range->min_slider_size;
if (height < range->min_slider_size ||
range->slider_size_fixed)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment