Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Kirill Smelkov
neo
Commits
1408fe57
Commit
1408fe57
authored
Mar 01, 2017
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
6246197d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
3 deletions
+11
-3
t/neo/storage/fs1/filestorage.go
t/neo/storage/fs1/filestorage.go
+9
-3
t/neo/storage/fs1/filestorage_test.go
t/neo/storage/fs1/filestorage_test.go
+2
-0
No files found.
t/neo/storage/fs1/filestorage.go
View file @
1408fe57
...
...
@@ -528,14 +528,20 @@ func Open(path string) (*FileStorage, error) {
return
nil
,
err
// XXX +context
}
err
=
txnhMax
.
Load
(
f
,
topPos
,
LoadAll
)
// XXX expect EOF but .PrevLen must be good
if
err
!=
nil
{
// expect EOF but .LenPrev must be good
if
err
!=
io
.
EOF
{
if
err
==
nil
{
err
=
fmt
.
Errorf
(
"no EOF after topPos"
)
// XXX err context
}
return
nil
,
err
// XXX +context
}
if
txnhMax
.
LenPrev
<=
0
{
panic
(
"could not read LenPrev @topPos"
)
// XXX err
}
err
=
txnhMax
.
LoadPrev
(
f
,
LoadAll
)
if
err
!=
nil
{
// XXX
panic
(
err
)
// XXX
}
...
...
t/neo/storage/fs1/filestorage_test.go
View file @
1408fe57
...
...
@@ -105,6 +105,8 @@ func TestLoad(t *testing.T) {
checkLoad
(
t
,
fs
,
xid
,
expect
)
}
return
// check iterating XXX move to separate test ?
// tids we will use for tid{Min,Max}
tidv
:=
[]
zodb
.
Tid
{
zodb
.
Tid
(
0
)}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment