mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-22 08:16:10 +01:00
🎨 Sync repo
This commit is contained in:
parent
3d71a2644b
commit
eaa83998a4
6 changed files with 86 additions and 81 deletions
|
|
@ -217,13 +217,14 @@ func AutoFlushBlockTree() {
|
|||
}
|
||||
}
|
||||
|
||||
func ReadBlockTree() (err error) {
|
||||
func InitBlockTree() {
|
||||
start := time.Now()
|
||||
|
||||
if nil == blocktreeFileLock {
|
||||
blocktreeFileLock = flock.New(util.BlockTreePath)
|
||||
}
|
||||
|
||||
var err error
|
||||
if err = blocktreeFileLock.Lock(); nil != err {
|
||||
util.LogErrorf("read block tree failed: %s", err)
|
||||
os.Exit(util.ExitCodeBlockTreeErr)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue