diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-12-09 09:35:49 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-12-09 09:35:49 -0500 |
| commit | 64b81b3a6471cd2f44a9524f0c346efe8e263c0f (patch) | |
| tree | d790041e0628f8d15f3b496feded41ea3caff3d5 /lib/vty.c | |
| parent | f7b0f4ef9e6efaafb77bf60ec897e931d340843b (diff) | |
| parent | fbdc1c0a8484301111582dcbef90b8ec646db6dd (diff) | |
Merge pull request #3442 from opensourcerouting/confirmed-commits
lib: add support for confirmed commits
Diffstat (limited to 'lib/vty.c')
| -rw-r--r-- | lib/vty.c | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -2714,6 +2714,14 @@ int vty_config_enter(struct vty *vty, bool private_config, bool exclusive) void vty_config_exit(struct vty *vty) { + /* Check if there's a pending confirmed commit. */ + if (vty->t_confirmed_commit_timeout) { + vty_out(vty, + "WARNING: exiting with a pending confirmed commit. Rolling back to previous configuration.\n\n"); + nb_cli_confirmed_commit_rollback(vty); + nb_cli_confirmed_commit_clean(vty); + } + vty_config_exclusive_unlock(vty); if (vty->candidate_config) { |
