Skip to content

Commit

Permalink
vrrp: fix reading of iproute2 conf files when directories don't exist
Browse files Browse the repository at this point in the history
Signed-off-by: Quentin Armitage <[email protected]>
  • Loading branch information
pqarmitage committed Nov 10, 2024
1 parent 4068c9b commit 042dc49
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/rttables.c
Original file line number Diff line number Diff line change
Expand Up @@ -412,8 +412,9 @@ initialise_list(list_head_t *l, const char *file_name, const rt_entry_t *default

read_file(path, l, max);
}

closedir(dir);
}
closedir(dir);
#endif

/* Now read the entries in the IPROUTE_ETC_DIR subdirectory */
Expand All @@ -425,8 +426,9 @@ initialise_list(list_head_t *l, const char *file_name, const rt_entry_t *default

read_file(path, l, max);
}

closedir(dir);
}
closedir(dir);

FREE_PTR(path);
#ifdef IPROUTE_USR_DIR
Expand Down

0 comments on commit 042dc49

Please sign in to comment.