[longomatch] Fix exception when no file is openned



commit b00f8badd0bd89572a8f81821cf08782e35174f6
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Mon Oct 6 10:52:14 2014 +0200

    Fix exception when no file is openned

 LongoMatch.GUI/Gui/Component/MediaFileChooser.cs |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/LongoMatch.GUI/Gui/Component/MediaFileChooser.cs 
b/LongoMatch.GUI/Gui/Component/MediaFileChooser.cs
index 9236453..38a28d1 100644
--- a/LongoMatch.GUI/Gui/Component/MediaFileChooser.cs
+++ b/LongoMatch.GUI/Gui/Component/MediaFileChooser.cs
@@ -104,7 +104,7 @@ namespace LongoMatch.Gui.Component
                {
                        if (FileChooserMode == FileChooserMode.MediaFile) {
                                MediaFile file = Misc.OpenFile (this);
-                               if (MediaFile != null) {
+                               if (file != null && MediaFile != null) {
                                        file.Offset = MediaFile.Offset;
                                }
                                MediaFile = file;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]