فهرست منبع

devmapper: clearer make the 'unknown base hash' error message more understandable

Solomon Hykes 11 سال پیش
والد
کامیت
dfb77274ce
1فایلهای تغییر یافته به همراه1 افزوده شده و 2 حذف شده
  1. 1 2
      devmapper/deviceset.go

+ 1 - 2
devmapper/deviceset.go

@@ -449,8 +449,7 @@ func (devices *DeviceSet) AddDevice(hash, baseHash string) error {
 
 
 	baseInfo := devices.Devices[baseHash]
 	baseInfo := devices.Devices[baseHash]
 	if baseInfo == nil {
 	if baseInfo == nil {
-		utils.Debugf("Base Hash not found")
-		return fmt.Errorf("Unknown base hash %s", baseHash)
+		return fmt.Errorf("Error adding device for '%s': can't find device for parent '%s'", hash, baseHash)
 	}
 	}
 
 
 	deviceId := devices.allocateDeviceId()
 	deviceId := devices.allocateDeviceId()