This moves the error variables that had been moved to the
internal/common package during recent refactoring to a non-internal
errors package, once again allowing consumers to test for particular
error conditions.
To preserve API compatibility with bbolt v1.3, these error variables
are also redefined in the bbolt package, with deprecation notice to
migrate to bbolt/errors.
Signed-off-by: Josh Rickmar <jrick@zettaport.com>
Points:
1. There are lots of duplicated definitions between bolt and
guts_cli, which is definitely not good.
2. The implementation in guts_cli also has issue, please
refer to https://github.com/etcd-io/bbolt/issues/391.
This refactoring can fix the issue.
Signed-off-by: Benjamin Wang <wachao@vmware.com>