mirror of
https://github.com/wavetermdev/waveterm.git
synced 2025-01-10 19:58:00 +01:00
close ptyout file
This commit is contained in:
parent
ec6c1f5a9a
commit
f8753830ff
@ -435,6 +435,7 @@ func HandleGetPtyOut(w http.ResponseWriter, r *http.Request) {
|
|||||||
w.Write([]byte(fmt.Sprintf("cannot open file '%s': %v", pathStr, err)))
|
w.Write([]byte(fmt.Sprintf("cannot open file '%s': %v", pathStr, err)))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
defer fd.Close()
|
||||||
w.WriteHeader(http.StatusOK)
|
w.WriteHeader(http.StatusOK)
|
||||||
io.Copy(w, fd)
|
io.Copy(w, fd)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user