banshee r3817 - in trunk/banshee: .	src/Dap/Banshee.Dap.Mtp/Banshee.Dap.Mtp
- From: gburt svn gnome org
 
- To: svn-commits-list gnome org
 
- Subject: banshee r3817 - in trunk/banshee: .	src/Dap/Banshee.Dap.Mtp/Banshee.Dap.Mtp
 
- Date: Thu, 24 Apr 2008 01:46:19 +0100 (BST)
 
Author: gburt
Date: Thu Apr 24 00:46:18 2008
New Revision: 3817
URL: http://svn.gnome.org/viewvc/banshee?rev=3817&view=rev
Log:
2008-04-23  Gabriel Burt  <gabriel burt gmail com>
	* src/Dap/Banshee.Dap.Mtp/Banshee.Dap.Mtp/MtpSource.cs: Be more careful
	when Disposing.
Modified:
   trunk/banshee/ChangeLog
   trunk/banshee/src/Dap/Banshee.Dap.Mtp/Banshee.Dap.Mtp/MtpSource.cs
Modified: trunk/banshee/src/Dap/Banshee.Dap.Mtp/Banshee.Dap.Mtp/MtpSource.cs
==============================================================================
--- trunk/banshee/src/Dap/Banshee.Dap.Mtp/Banshee.Dap.Mtp/MtpSource.cs	(original)
+++ trunk/banshee/src/Dap/Banshee.Dap.Mtp/Banshee.Dap.Mtp/MtpSource.cs	Thu Apr 24 00:46:18 2008
@@ -277,10 +277,14 @@
         public override void Dispose ()
         {
 			base.Dispose ();
-            lock (mtp_device) {
-                mtp_device.Dispose ();
+
+            if (mtp_device != null) {
+                lock (mtp_device) {
+                    mtp_device.Dispose ();
+                }
             }
             mtp_device = null;
+
             mtp_source = null;
         }
 
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]