diff options
Diffstat (limited to 'mgmtd/mgmt_history.c')
| -rw-r--r-- | mgmtd/mgmt_history.c | 4 | 
1 files changed, 3 insertions, 1 deletions
diff --git a/mgmtd/mgmt_history.c b/mgmtd/mgmt_history.c index 54eb45fdf4..89a7a60166 100644 --- a/mgmtd/mgmt_history.c +++ b/mgmtd/mgmt_history.c @@ -211,7 +211,7 @@ static int mgmt_history_rollback_to_cmt(struct vty *vty,  		return -1;  	} -	ret = mgmt_ds_write_lock(dst_ds_ctx); +	ret = mgmt_ds_lock(dst_ds_ctx, vty->mgmt_session_id);  	if (ret != 0) {  		vty_out(vty,  			"Failed to lock the DS %u for rollback Reason: %s!\n", @@ -243,6 +243,8 @@ static int mgmt_history_rollback_to_cmt(struct vty *vty,  	mgmt_history_dump_cmt_record_index(); +	/* XXX chopps when does this get unlocked? */ +  	/*  	 * Block the rollback command from returning till the rollback  	 * is completed. On rollback completion mgmt_history_rollback_complete()  | 
