Skip to content

Commit 7a8a614

Browse files
Fix typos
Signed-off-by: Mauricio Vasquez B <mauriciovasquezbernal@gmail.com>
1 parent 09d1bd5 commit 7a8a614

2 files changed

Lines changed: 10 additions & 4 deletions

File tree

src/polycubed/src/polycubed.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ std::shared_ptr<spdlog::logger> logger;
5454
// create core instance
5555
PolycubedCore *core;
5656
RestServer *restserver;
57-
int netlink_nofitication_id = -1;
57+
int netlink_notification_id = -1;
5858

5959
void shutdown() {
6060
static bool done = false;
@@ -70,9 +70,9 @@ void shutdown() {
7070
delete restserver;
7171
}
7272

73-
if (netlink_nofitication_id != -1) {
73+
if (netlink_notification_id != -1) {
7474
Netlink::getInstance().unregisterObserver(Netlink::Event::LINK_DELETED,
75-
netlink_nofitication_id);
75+
netlink_notification_id);
7676
}
7777

7878
logger->info("polycubed is shutting down. Bye!");
@@ -255,7 +255,7 @@ int main(int argc, char *argv[]) {
255255
core = new PolycubedCore(base_model);
256256

257257
// register handler to detect interfaces that are deleted
258-
netlink_nofitication_id = Netlink::getInstance().registerObserver(
258+
netlink_notification_id = Netlink::getInstance().registerObserver(
259259
Netlink::Event::LINK_DELETED,
260260
std::bind(&ServiceController::netlink_notification, std::placeholders::_1,
261261
std::placeholders::_2));

src/polycubed/src/service_controller.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,12 @@ bool ServiceController::parse_peer_name(const std::string &peer,
284284
return true;
285285
}
286286

287+
/*
288+
* This function in on charge of setting the peer of ports
289+
* connected to netdevs when they are removed.
290+
* This function also removes the ExtIface object if this is
291+
* not already removed.
292+
*/
287293
void ServiceController::netlink_notification(int ifindex,
288294
const std::string &ifname) {
289295
std::lock_guard<std::mutex> guard(service_ctrl_mutex_);

0 commit comments

Comments
 (0)