plugins/loopback: return empty result
authorStefan Junker <mail@stefanjunker.de>
Wed, 2 Mar 2016 11:53:02 +0000 (12:53 +0100)
committerStefan Junker <mail@stefanjunker.de>
Wed, 2 Mar 2016 14:27:00 +0000 (15:27 +0100)
This is needed to conform to the specification and allow successful
unmarshalling in the invoker.

plugins/main/loopback/loopback.go

index d0e9646..eb02eb1 100644 (file)
@@ -5,6 +5,7 @@ import (
 
        "github.com/appc/cni/pkg/ns"
        "github.com/appc/cni/pkg/skel"
+       "github.com/appc/cni/pkg/types"
        "github.com/vishvananda/netlink"
 )
 
@@ -27,7 +28,8 @@ func cmdAdd(args *skel.CmdArgs) error {
                return err // not tested
        }
 
-       return nil
+       result := types.Result{}
+       return result.Print()
 }
 
 func cmdDel(args *skel.CmdArgs) error {