summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/vty.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/vty.h b/lib/vty.h
index c7352efbd3..a0b8e8afa1 100644
--- a/lib/vty.h
+++ b/lib/vty.h
@@ -254,7 +254,8 @@ static inline void vty_push_context(struct vty *vty, int node, uint64_t id)
#define VTY_CHECK_XPATH \
do { \
- if (vty->xpath_index > 0 \
+ if (vty->type != VTY_FILE && !vty->private_config \
+ && vty->xpath_index > 0 \
&& !yang_dnode_exists(vty->candidate_config->dnode, \
VTY_CURR_XPATH)) { \
vty_out(vty, \