summaryrefslogtreecommitdiffstats
path: root/ctrl
diff options
context:
space:
mode:
authorJordan Augé <jordan.auge+fdio@cisco.com>2019-11-25 10:24:15 +0000
committerGerrit Code Review <gerrit@fd.io>2019-11-25 10:24:15 +0000
commitb3ee2ed8602c909f8d5096e9d8d44aa345093566 (patch)
treeeeb8356ceae8b25d02e93ccab97fda31625c4ba1 /ctrl
parent4bdc720d1a7d13f19eae6ba7e14b00cbfbd37ce0 (diff)
parentaac4a3d3163ee4085fc00426cf31fe3143dd191e (diff)
Merge "[HICN-408] add a face manager interface for face priority control"
Diffstat (limited to 'ctrl')
-rw-r--r--ctrl/facemgr/src/interfaces/priority_controller/priority_controller.c24
-rw-r--r--ctrl/libhicnctrl/src/api.c2
2 files changed, 23 insertions, 3 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);
diff --git a/ctrl/libhicnctrl/src/api.c b/ctrl/libhicnctrl/src/api.c
index e7caf4f1c..ea4ed69c2 100644
--- a/ctrl/libhicnctrl/src/api.c
+++ b/ctrl/libhicnctrl/src/api.c
@@ -2268,7 +2268,7 @@ hc_face_get(hc_sock_t * s, hc_face_t * face, hc_face_t ** face_found)
int rc = hc_face_snprintf(face_s, MAXSZ_HC_FACE, face);
if (rc >= MAXSZ_HC_FACE)
WARN("[hc_face_get] Unexpected truncation of face string");
- DEBUG("[hc_face_get] face=%s");
+ DEBUG("[hc_face_get] face=%s", face_s);
switch(face->face.type)
{