Skip to content

Commit

Permalink
catch absurd but possible div-by-zero
Browse files Browse the repository at this point in the history
  • Loading branch information
luebking committed Aug 26, 2016
1 parent d4e9bb7 commit 4304e66
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Toolbar.cc
Original file line number Diff line number Diff line change
Expand Up @@ -936,7 +936,7 @@ void Toolbar::rearrangeItems() {
if (relative_items) {
if (relative_width <= width - fixed_width && stretch_items) {
relative_width = int(width - fixed_width - relative_width)/stretch_items;
} else {
} else if (relative_width) {
stretch_factor = float(width - fixed_width)/relative_width;
relative_width = 0;
}
Expand Down

0 comments on commit 4304e66

Please sign in to comment.