storage kit: don't expose the dev_t in BPartition::Mount()
Comments to #9672 agree that there's really no need to expose the dev_t handle, thus simplifying the API. The dev_t handle, if required, can be retrieved via BPartition::GetVolume() instead.
This commit is contained in:
@@ -70,8 +70,7 @@ public:
|
|||||||
|
|
||||||
status_t Mount(const char* mountPoint = NULL,
|
status_t Mount(const char* mountPoint = NULL,
|
||||||
uint32 mountFlags = 0,
|
uint32 mountFlags = 0,
|
||||||
const char* parameters = NULL,
|
const char* parameters = NULL);
|
||||||
dev_t* devicePointer = NULL);
|
|
||||||
status_t Unmount(uint32 unmountFlags = 0);
|
status_t Unmount(uint32 unmountFlags = 0);
|
||||||
|
|
||||||
// Hierarchy Info
|
// Hierarchy Info
|
||||||
|
|||||||
@@ -518,8 +518,6 @@ BPartition::GetMountPoint(BPath* mountPoint) const
|
|||||||
\param mountFlags Currently only \c B_MOUNT_READ_ONLY is defined, which
|
\param mountFlags Currently only \c B_MOUNT_READ_ONLY is defined, which
|
||||||
forces the volume to be mounted read-only.
|
forces the volume to be mounted read-only.
|
||||||
\param parameters File system specific mount parameters.
|
\param parameters File system specific mount parameters.
|
||||||
\param devicePointer Reference to the mounted filesystem for the programs
|
|
||||||
interested in it
|
|
||||||
\return \c B_OK, if everything went fine, another error code otherwise.
|
\return \c B_OK, if everything went fine, another error code otherwise.
|
||||||
*/
|
*/
|
||||||
status_t
|
status_t
|
||||||
@@ -571,12 +569,9 @@ BPartition::Mount(const char* mountPoint, uint32 mountFlags,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// update object, if successful
|
// update object, if successful
|
||||||
if (device >= 0) {
|
if (device >= 0)
|
||||||
error = Device()->Update();
|
return Device()->Update();
|
||||||
if (devicePointer != NULL)
|
|
||||||
*devicePointer = device;
|
|
||||||
return error;
|
|
||||||
}
|
|
||||||
return B_ERROR;
|
return B_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user