GNOME Bugzilla – Bug 316468
Divisions by zero?
Last modified: 2005-11-23 15:23:12 UTC
Here's a patch from Steve Grubb which marks various potential divisions by zero found by an automated checker tool. I don't think any are of concern, but it might be good to clean up (one is in test code, ther others can't be hit because the sample string is always non-zero length.
Created attachment 52306 [details] [review] Patch marking divisons by zero
Comment on attachment 52306 [details] [review] Patch marking divisons by zero Marking as needs-work since it isn't a fix patch.
2005-11-23 Behdad Esfahbod <behdad@gnome.org> Protect against possible division by zeros (#316468, Steve Grubb) * pango/pango-context.c (update_metrics_from_items), pango/pango-fontset.c (pango_fontset_real_get_metrics): If count is zero, do not alter approximate_{char,digit}_width. * pango/opentype/disasm.c: Err on invalid DeltaFormat.