Removed obsolete disk.Mountpoint fix

Fixed upstream in gopsutil
This commit is contained in:
Caleb Bassi 2018-08-11 16:34:43 -07:00
parent 898a443994
commit 04d3dca8ca

View File

@ -58,12 +58,9 @@ func (self *Disk) update() {
for _, Part := range Partitions {
device := strings.Replace(Part.Device, "/dev/", "", -1)
if _, ok := self.Partitions[device]; !ok {
// https://github.com/shirou/gopsutil/issues/555
// have to remove artifacts produced by gopsutil when there's a space in the mount path
mountPoint := strings.Replace(Part.Mountpoint, "\\040", " ", -1)
self.Partitions[device] = &Partition{
Device: device,
Mount: mountPoint,
Mount: Part.Mountpoint,
}
}
}