Skip to content

Commit 8b0a1b8

Browse files
magerstamCopilot
andauthored
Update internal/image/imageconvert/imageconvert.go
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 5bbc744 commit 8b0a1b8

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

internal/image/imageconvert/imageconvert.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,8 @@ func shellSingleQuote(s string) string {
147147
return "'" + strings.ReplaceAll(s, "'", `'"'"'`) + "'"
148148
}
149149

150+
// formatFromExt provides a fallback format detection based on common file
151+
// extensions when qemu-img based detection fails.
150152
func formatFromExt(filePath string) string {
151153
switch strings.ToLower(filepath.Ext(filePath)) {
152154
case ".raw", ".img":

0 commit comments

Comments
 (0)