mirror of
https://github.com/restic/restic.git
synced 2025-08-21 17:18:03 +00:00
server: Check repository version
This commit is contained in:
@@ -559,6 +559,10 @@ func (s *Server) loadConfig(cfg *Config) error {
|
||||
return err
|
||||
}
|
||||
|
||||
if cfg.Version != RepositoryVersion {
|
||||
return errors.New("unsupported repository version")
|
||||
}
|
||||
|
||||
if !cfg.ChunkerPolynomial.Irreducible() {
|
||||
return errors.New("invalid chunker polynomial")
|
||||
}
|
||||
|
Reference in New Issue
Block a user