mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-19 10:46:58 +08:00
Merge pull request #6506 from ioito/automated-cherry-pick-of-#6505-upstream-release-3.2
Automated cherry pick of #6505: fix: 上传镜像为转换列表之外时,subformat状态异常
This commit is contained in:
@@ -1005,7 +1005,7 @@ func (self *SImage) MigrateSubImage() error {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if self.GetImageType() != api.ImageTypeISO && imgInst.IsSparse() {
|
||||
if self.GetImageType() != api.ImageTypeISO && imgInst.IsSparse() && utils.IsInStringArray(self.DiskFormat, options.Options.TargetImageFormats) {
|
||||
// need to convert again
|
||||
return self.newSubformat(qemuimg.String2ImageFormat(self.DiskFormat), false)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user