search for: dumpconnection

Displaying 1 result from an estimated 1 matches for "dumpconnection".

Did you mean: dump_connections
2020 Apr 24
1
[PATCH nbdkit] golang: Pass Plugin and Connection by reference not value.
...+func main() {} diff --git a/plugins/golang/examples/dump-plugin/dumpplugin.go b/plugins/golang/examples/dump-plugin/dumpplugin.go index 518be078..d30ec3f1 100644 --- a/plugins/golang/examples/dump-plugin/dumpplugin.go +++ b/plugins/golang/examples/dump-plugin/dumpplugin.go @@ -51,19 +51,19 @@ type DumpConnection struct { var size uint64 = 1024 * 1024 -func (p DumpPlugin) DumpPlugin() { +func (p *DumpPlugin) DumpPlugin() { fmt.Println("golang_dump_plugin=1") } -func (p DumpPlugin) Open(readonly bool) (nbdkit.ConnectionInterface, error) { +func (p *DumpPlugin) Open(readonly bool) (nbdkit....