]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
net_sched: cls_api: fix return value for non-existant classifiers
authorPatrick McHardy <kaber@trash.net>
Tue, 20 May 2008 21:34:46 +0000 (14:34 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 20 May 2008 21:34:46 +0000 (14:34 -0700)
cls_api should return ENOENT when the requested classifier doesn't
exist.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/cls_api.c

index 1086df7478bcee1309702022c7824403e9fbd47c..9360fc81e8c7e8099e2cd105d67bbec1511324b6 100644 (file)
@@ -220,7 +220,7 @@ replay:
                tp = kzalloc(sizeof(*tp), GFP_KERNEL);
                if (tp == NULL)
                        goto errout;
-               err = -EINVAL;
+               err = -ENOENT;
                tp_ops = tcf_proto_lookup_ops(tca[TCA_KIND]);
                if (tp_ops == NULL) {
 #ifdef CONFIG_KMOD