Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unused raft_term_t term in log_load_from_snapshot #114

Open
debug-zhang opened this issue Mar 8, 2021 · 0 comments
Open

Unused raft_term_t term in log_load_from_snapshot #114

debug-zhang opened this issue Mar 8, 2021 · 0 comments

Comments

@debug-zhang
Copy link

In raft_log.c

int log_load_from_snapshot(log_t *me_, raft_index_t idx, raft_term_t term)
{
    log_private_t* me = (log_private_t*)me_;

    log_clear_entries(me_);
    log_clear(me_);
    me->base = idx;

    return 0;
}

The term is unused.

So could be safely deleted from source code?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant