aboutsummaryrefslogtreecommitdiffstats
path: root/ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c
diff options
context:
space:
mode:
authorJordan Augé <jordan.auge+fdio@cisco.com>2019-11-25 11:20:32 +0100
committerJordan Augé <jordan.auge+fdio@cisco.com>2019-11-25 11:20:32 +0100
commitaac4a3d3163ee4085fc00426cf31fe3143dd191e (patch)
tree7b8fca7f0ed791b89ee1f7b7fa5438febf00540a /ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c
parent93b0b7a95922defa19951dde01b1dce4047bb0e7 (diff)
[HICN-408] add a face manager interface for face priority control
Change-Id: I07cd4c100251c42ef32117a515e8e9e39b9c3031 Signed-off-by: Jordan Augé <jordan.auge+fdio@cisco.com>
Diffstat (limited to 'ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c')
-rw-r--r--ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c24
1 files changed, 22 insertions, 2 deletions
diff --git a/ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c b/ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c
index b8e7271bb..a64796857 100644
--- a/ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c
+++ b/ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c
@@ -1,3 +1,23 @@
+/*
+ * Copyright (c) 2017-2019 Cisco and/or its affiliates.
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at:
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * \file priority_controller.c
+ * \brief Implementation of Priority Controller interface
+ */
+
#include <assert.h>
#include <sys/socket.h>
#include <sys/un.h>
@@ -112,10 +132,10 @@ int priority_controller_callback(interface_t * interface, int fd, void * unused)
INFO("Priority controller configuring both Cellular and Wi-Fi preferred");
break;
default:
- INFO("Priority cntroller invalid data received from updown server. Ignoring...");
+ INFO("Priority controller invalid data received from updown server. Ignoring...");
facelet_free(facelet_w);
facelet_free(facelet_c);
- return -1;
+ return 0;
}
facelet_set_event(facelet_w, FACELET_EVENT_UPDATE);