[haiku-commits] Re: r41986 - haiku/trunk/src/kits/storage/disk_device

  • From: Stephan Assmus <superstippi@xxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Tue, 07 Jun 2011 12:34:54 +0200

Hi,

Am 07.06.2011 00:23, schrieb korli@xxxxxxxxxxxxxxxx:
Log:
Second try at fixing #7572 (after r41842). Please review.


Modified: haiku/trunk/src/kits/storage/disk_device/Partition.cpp
===================================================================
--- haiku/trunk/src/kits/storage/disk_device/Partition.cpp      2011-06-06 
20:37:43 UTC (rev 41985)
+++ haiku/trunk/src/kits/storage/disk_device/Partition.cpp      2011-06-06 
22:23:44 UTC (rev 41986)
@@ -1176,7 +1176,7 @@
  bool
  BPartition::CanInitialize(const char* diskSystem) const
  {
-       return fDelegate&&  fDelegate->CanInitialize(diskSystem);
+       return IsDevice() || (fDelegate&&  
fDelegate->CanInitialize(diskSystem));
  }

Without having looked at the surounding code recently, it looks a bit as if a partition would now always claim support for initializing if it's a device, even when the partitioning system in question does not support initializing. I think DriveSetup does not show entries for partitioning systems that don't support initializing, but technically, a partition may now claim support for initializing as exFAT when it is a device, for example. Don't know if that is really the case, as I said, just judging by the small bit of code above.

Best regards,
-Stephan

Other related posts: