mirror of
https://gitcode.com/gitea/gitea.git
synced 2025-05-28 21:41:22 +08:00
Correct broken unaligned load/store in armv5 (#1355)
Update vendor github.com/boltdb/bolt to take care of the issue #1354.
This commit is contained in:

committed by
Lunny Xiao

parent
d800305b34
commit
a78a0266c4
5
vendor/github.com/boltdb/bolt/node.go
generated
vendored
5
vendor/github.com/boltdb/bolt/node.go
generated
vendored
@ -201,6 +201,11 @@ func (n *node) write(p *page) {
|
||||
}
|
||||
p.count = uint16(len(n.inodes))
|
||||
|
||||
// Stop here if there are no items to write.
|
||||
if p.count == 0 {
|
||||
return
|
||||
}
|
||||
|
||||
// Loop over each item and write it to the page.
|
||||
b := (*[maxAllocSize]byte)(unsafe.Pointer(&p.ptr))[n.pageElementSize()*len(n.inodes):]
|
||||
for i, item := range n.inodes {
|
||||
|
Reference in New Issue
Block a user