diff options
author | sr55 <[email protected]> | 2012-02-15 20:03:10 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2012-02-15 20:03:10 +0000 |
commit | 1d8bc5dd7d36da0167e572762b6f20db20289012 (patch) | |
tree | 20e3a5164ff24bb6d44504e587fb14dc9a92d5bd /win/CS/HandBrake.ApplicationServices/Services/QueueManager.cs | |
parent | 4da15bcbbbd800b7af230294224f0d7248e8dd72 (diff) |
WinGui: Fix a couple of trival gui bugs and force all exceptions to be handled by the built-in exception handler rather than the .NET one.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4449 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrake.ApplicationServices/Services/QueueManager.cs')
-rw-r--r-- | win/CS/HandBrake.ApplicationServices/Services/QueueManager.cs | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Services/QueueManager.cs b/win/CS/HandBrake.ApplicationServices/Services/QueueManager.cs index 6cddd2707..7c60d1e86 100644 --- a/win/CS/HandBrake.ApplicationServices/Services/QueueManager.cs +++ b/win/CS/HandBrake.ApplicationServices/Services/QueueManager.cs @@ -322,7 +322,16 @@ namespace HandBrake.ApplicationServices.Services {
XmlSerializer serializer = new XmlSerializer(typeof(List<QueueTask>));
- List<QueueTask> list = serializer.Deserialize(strm) as List<QueueTask>;
+ List<QueueTask> list;
+
+ try
+ {
+ list = serializer.Deserialize(strm) as List<QueueTask>;
+ }
+ catch (Exception exc)
+ {
+ throw new GeneralApplicationException("Unable to restore queue file.", "The file may be corrupted or from an older incompatible version of HandBrake", exc);
+ }
if (list != null)
foreach (QueueTask item in list)
|