Skip to content
This repository has been archived by the owner on Sep 23, 2023. It is now read-only.

Commit

Permalink
Revert "save"
Browse files Browse the repository at this point in the history
This reverts commit ef20b06.
  • Loading branch information
AskAlexSharov committed Dec 27, 2021
1 parent ef20b06 commit dd363ae
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion compress/compress.go
Original file line number Diff line number Diff line change
Expand Up @@ -1164,7 +1164,7 @@ func (c *Compressor) processSuperstring() error {
lastK = k
}
}
score := uint64(repeats * int(l))
score := uint64(repeats * int(l-4))
if score >= c.minPatternScore {
// Dictionary key is the concatenation of the score and the dictionary word (to later aggregate the scores from multiple chunks)
c.collectBuf = c.collectBuf[:8]
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ go 1.16
require (
github.com/VictoriaMetrics/metrics v1.18.1
github.com/c2h5oh/datasize v0.0.0-20200825124411-48ed595a09d2
github.com/flanglet/kanzi-go v1.9.1-0.20211212184056-72dda96261ee
github.com/flanglet/kanzi-go v1.9.0
github.com/go-stack/stack v1.8.1
github.com/google/btree v1.0.1
github.com/grpc-ecosystem/go-grpc-middleware v1.3.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1m
github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk=
github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0=
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/flanglet/kanzi-go v1.9.1-0.20211212184056-72dda96261ee h1:CaVlPeoz5kJQ+cAOV+ZDdlr3J2FmKyNkGu9LY+x7cDM=
github.com/flanglet/kanzi-go v1.9.1-0.20211212184056-72dda96261ee/go.mod h1:/sUSVgDcbjsisuW42GPDgaMqvJ0McZERNICnD7b1nRA=
github.com/flanglet/kanzi-go v1.9.0 h1:bhpFJaGIKGio575OO6mWFec658OKKt7DKS9kMRSl6/U=
github.com/flanglet/kanzi-go v1.9.0/go.mod h1:/sUSVgDcbjsisuW42GPDgaMqvJ0McZERNICnD7b1nRA=
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
Expand Down
1 change: 1 addition & 0 deletions kv/mdbx/kv_mdbx.go
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,7 @@ func (db *MdbxKV) BeginRw(_ context.Context) (txn kv.RwTx, err error) {
db.wg.Add(1)
}
}()

tx, err := db.env.BeginTxn(nil, 0)
if err != nil {
runtime.UnlockOSThread() // unlock only in case of error. normal flow is "defer .Rollback()"
Expand Down

0 comments on commit dd363ae

Please sign in to comment.