summaryrefslogtreecommitdiff
path: root/pkg/varlinkapi/transfers.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-04-09 14:55:45 +0200
committerGitHub <noreply@github.com>2020-04-09 14:55:45 +0200
commit555b30e9ebdf82dfc2e0c7ddd9f0f8b51ccb4a39 (patch)
treee56d6b21c07df5e3a442ed423a6d6cba8d22247f /pkg/varlinkapi/transfers.go
parent655139fdda20819160b2baad840429a80d6285e5 (diff)
parente0847f5457edfdeb17dad259f1cd06b1d4cec93e (diff)
downloadpodman-555b30e9ebdf82dfc2e0c7ddd9f0f8b51ccb4a39.tar.gz
podman-555b30e9ebdf82dfc2e0c7ddd9f0f8b51ccb4a39.tar.bz2
podman-555b30e9ebdf82dfc2e0c7ddd9f0f8b51ccb4a39.zip
Merge pull request #5634 from jwhonce/wip/service
V2 podman system service
Diffstat (limited to 'pkg/varlinkapi/transfers.go')
-rw-r--r--pkg/varlinkapi/transfers.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/pkg/varlinkapi/transfers.go b/pkg/varlinkapi/transfers.go
index 654da276e..9df8ffcdc 100644
--- a/pkg/varlinkapi/transfers.go
+++ b/pkg/varlinkapi/transfers.go
@@ -4,7 +4,6 @@ package varlinkapi
import (
"bufio"
- "fmt"
"io"
"io/ioutil"
"os"
@@ -14,7 +13,7 @@ import (
)
// SendFile allows a client to send a file to the varlink server
-func (i *LibpodAPI) SendFile(call iopodman.VarlinkCall, ftype string, length int64) error {
+func (i *VarlinkAPI) SendFile(call iopodman.VarlinkCall, ftype string, length int64) error {
if !call.WantsUpgrade() {
return call.ReplyErrorOccurred("client must use upgraded connection to send files")
}
@@ -40,14 +39,14 @@ func (i *LibpodAPI) SendFile(call iopodman.VarlinkCall, ftype string, length int
logrus.Debugf("successfully received %s", outputFile.Name())
// Send an ACK to the client
- call.Call.Writer.WriteString(fmt.Sprintf("%s:", outputFile.Name()))
+ call.Call.Writer.WriteString(outputFile.Name())
call.Call.Writer.Flush()
return nil
}
// ReceiveFile allows the varlink server to send a file to a client
-func (i *LibpodAPI) ReceiveFile(call iopodman.VarlinkCall, filepath string, delete bool) error {
+func (i *VarlinkAPI) ReceiveFile(call iopodman.VarlinkCall, filepath string, delete bool) error {
if !call.WantsUpgrade() {
return call.ReplyErrorOccurred("client must use upgraded connection to send files")
}