summaryrefslogtreecommitdiff
path: root/pkg/varlinkapi/transfers.go
diff options
context:
space:
mode:
authorBrent Baude <bbaude@redhat.com>2020-05-18 12:41:25 -0500
committerBrent Baude <bbaude@redhat.com>2020-05-18 12:45:00 -0500
commit6f224d0886a8b721439c42fb6619fd592834d12e (patch)
treee9318d62610bcd91a3ae98fca6cd2aa650cbb892 /pkg/varlinkapi/transfers.go
parentd4587c6074e4b4e3673cf495f0c4cd2811742791 (diff)
downloadpodman-6f224d0886a8b721439c42fb6619fd592834d12e.tar.gz
podman-6f224d0886a8b721439c42fb6619fd592834d12e.tar.bz2
podman-6f224d0886a8b721439c42fb6619fd592834d12e.zip
Fix EOM for SendFile
To terminate a connection of varlink, say after sending a file, we need to send a message containing a delimiter of ':' so the client knows to hang up. Fixes: #6237 Signed-off-by: Brent Baude <bbaude@redhat.com>
Diffstat (limited to 'pkg/varlinkapi/transfers.go')
-rw-r--r--pkg/varlinkapi/transfers.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/varlinkapi/transfers.go b/pkg/varlinkapi/transfers.go
index 9df8ffcdc..aed6e054d 100644
--- a/pkg/varlinkapi/transfers.go
+++ b/pkg/varlinkapi/transfers.go
@@ -39,7 +39,7 @@ func (i *VarlinkAPI) SendFile(call iopodman.VarlinkCall, ftype string, length in
logrus.Debugf("successfully received %s", outputFile.Name())
// Send an ACK to the client
- call.Call.Writer.WriteString(outputFile.Name())
+ call.Call.Writer.WriteString(outputFile.Name() + ":")
call.Call.Writer.Flush()
return nil