mirror of
https://github.com/schollz/croc.git
synced 2025-10-11 13:21:00 +02:00
debugging
This commit is contained in:
parent
c71fb49d27
commit
1f3711fdba
1 changed files with 2 additions and 1 deletions
|
@ -148,13 +148,14 @@ func (s *Session) receiveData(pathToFile string, fileSize int64) error {
|
|||
}
|
||||
}
|
||||
|
||||
f, err := os.OpenFile(pathToFile, os.O_RDWR|os.O_CREATE, 0755)
|
||||
f, err := os.Open(pathToFile)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer func() {
|
||||
log.Debugln("Stopped receiving data...")
|
||||
f.Close()
|
||||
os.Exit(0)
|
||||
}()
|
||||
|
||||
firstByte := true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue