From 8bfcc38a3272405bb148da929393405c16cf3db8 Mon Sep 17 00:00:00 2001 From: jstebbins Date: Mon, 11 Aug 2014 14:49:33 +0000 Subject: LinGui: protect against possible divide by 0 git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6287 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- gtk/src/hb-backend.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gtk/src') diff --git a/gtk/src/hb-backend.c b/gtk/src/hb-backend.c index e6302cdda..8b234c7c0 100644 --- a/gtk/src/hb-backend.c +++ b/gtk/src/hb-backend.c @@ -3519,6 +3519,8 @@ ghb_set_scale_settings(GValue *settings, gint mode) // First configure widgets mod = ghb_settings_combo_int(settings, "PictureModulus"); + if (mod <= 0) + mod = 16; keep_aspect = ghb_settings_get_boolean(settings, "PictureKeepRatio"); autocrop = ghb_settings_get_boolean(settings, "PictureAutoCrop"); autoscale = ghb_settings_get_boolean(settings, "autoscale"); -- cgit v1.2.3