raft: do not restore snapshot if local raft has longer matching history

Raft should not restore the snapshot if it has longer matching history.
Or restoring snapshot might remove the matched entries.
Merge pull request #1837 from xiang90/fix_restore

raft: do not restore snapshot if local raft has longer matching history