summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsr55 <[email protected]>2009-09-29 18:30:38 +0000
committersr55 <[email protected]>2009-09-29 18:30:38 +0000
commit108fc8c802b2d1dd55a6f5138bf06a1f4182cf78 (patch)
treef2a0a90ddccfa67bb79e9c68a1bdc3ca3f4cf93a
parent14c4179e3f6e5f7bb0d3ad29a25d372d73fda001 (diff)
WinGui:
- Fix a strange exception error is high profile preset is selected before the first scan. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2849 b64f7644-9d1e-0410-96f1-a4d463321fa5
-rw-r--r--win/C#/Controls/PictureSettings.cs2
1 files changed, 2 insertions, 0 deletions
diff --git a/win/C#/Controls/PictureSettings.cs b/win/C#/Controls/PictureSettings.cs
index 70273cc64..bf43b6465 100644
--- a/win/C#/Controls/PictureSettings.cs
+++ b/win/C#/Controls/PictureSettings.cs
@@ -453,6 +453,8 @@ namespace Handbrake.Controls
double pixel_aspect_height = width;
double disWidthLoose = (width * pixel_aspect_width / pixel_aspect_height);
+ if (double.IsNaN(disWidthLoose))
+ disWidthLoose = 0;
return new Size((int)disWidthLoose, (int)height);
case 3: