Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neoppod
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Levin Zimmermann
neoppod
Commits
9a2b7ac5
Commit
9a2b7ac5
authored
Mar 06, 2017
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
270fad44
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
t/neo/zodb/cmd/zodbdump/zodbdump.go
t/neo/zodb/cmd/zodbdump/zodbdump.go
+3
-2
No files found.
t/neo/zodb/cmd/zodbdump/zodbdump.go
View file @
9a2b7ac5
...
@@ -50,6 +50,7 @@ func zodbDump(w io.Writer, stor zodb.IStorage, tidMin, tidMax zodb.Tid, hashOnly
...
@@ -50,6 +50,7 @@ func zodbDump(w io.Writer, stor zodb.IStorage, tidMin, tidMax zodb.Tid, hashOnly
var
retErr
error
var
retErr
error
iter
:=
stor
.
Iterate
(
tidMin
,
tidMax
)
iter
:=
stor
.
Iterate
(
tidMin
,
tidMax
)
// transactions
for
{
for
{
txni
,
dataIter
,
err
:=
iter
.
NextTxn
()
txni
,
dataIter
,
err
:=
iter
.
NextTxn
()
if
err
!=
nil
{
if
err
!=
nil
{
...
@@ -70,6 +71,7 @@ func zodbDump(w io.Writer, stor zodb.IStorage, tidMin, tidMax zodb.Tid, hashOnly
...
@@ -70,6 +71,7 @@ func zodbDump(w io.Writer, stor zodb.IStorage, tidMin, tidMax zodb.Tid, hashOnly
}
}
// data records
for
{
for
{
datai
,
err
:=
dataIter
.
NextData
()
datai
,
err
:=
dataIter
.
NextData
()
if
err
!=
nil
{
if
err
!=
nil
{
...
@@ -92,7 +94,7 @@ func zodbDump(w io.Writer, stor zodb.IStorage, tidMin, tidMax zodb.Tid, hashOnly
...
@@ -92,7 +94,7 @@ func zodbDump(w io.Writer, stor zodb.IStorage, tidMin, tidMax zodb.Tid, hashOnly
entry
+=
"from "
+
datai
.
DataTid
.
String
()
entry
+=
"from "
+
datai
.
DataTid
.
String
()
default
:
default
:
entry
+=
fmt
.
Sprintf
(
"sha1:%
s
%d"
,
sha1
.
Sum
(
datai
.
Data
),
len
(
datai
.
Data
))
entry
+=
fmt
.
Sprintf
(
"sha1:%
x
%d"
,
sha1
.
Sum
(
datai
.
Data
),
len
(
datai
.
Data
))
writeData
=
true
writeData
=
true
}
}
...
@@ -108,7 +110,6 @@ func zodbDump(w io.Writer, stor zodb.IStorage, tidMin, tidMax zodb.Tid, hashOnly
...
@@ -108,7 +110,6 @@ func zodbDump(w io.Writer, stor zodb.IStorage, tidMin, tidMax zodb.Tid, hashOnly
break
break
}
}
}
}
}
}
}
}
...
...
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