Skip to content

Commit

Permalink
Indent
Browse files Browse the repository at this point in the history
  • Loading branch information
lucaderi committed Feb 28, 2025
1 parent a2e5891 commit 4106ccc
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/Utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4607,6 +4607,7 @@ int Utils::ntop_findalldevs(ntop_if_t **alldevsp) {
while (pfdev != NULL) {
/* merge with info from pcap */
pdev = pdevs;

while (pdev != NULL) {
if (pfdev->system_name && strcmp(pfdev->system_name, pdev->name) == 0)
break;
Expand All @@ -4619,10 +4620,8 @@ int Utils::ntop_findalldevs(ntop_if_t **alldevsp) {
cur = (ntop_if_t *)calloc(1, sizeof(ntop_if_t));

if (cur) {
cur->name =
strdup(pfdev->system_name ? pfdev->system_name : pfdev->name);
cur->description =
strdup((pdev && pdev->description) ? pdev->description : "");
cur->name = strdup(pfdev->system_name ? pfdev->system_name : pfdev->name);
cur->description = strdup((pdev && pdev->description) ? pdev->description : "");
cur->module = strdup(pfdev->module);
cur->license = pfdev->license;
cur->ifindex = pfdev->ifindex;
Expand All @@ -4632,7 +4631,7 @@ int Utils::ntop_findalldevs(ntop_if_t **alldevsp) {
tail = cur;
}
}

pfdev = pfdev->next;
}
#endif
Expand Down

0 comments on commit 4106ccc

Please sign in to comment.