[sword-devel] imp2gbs problem

Peter von Kaehne refdoc at gmx.net
Fri Aug 18 07:29:09 MST 2017


imp2gbs appears to have a problem. I certainly can not coax any sense
out of it. 

It goes into an eternal loop which needs interrupting by hand. 

Please have a look at the attached test input file, a shortened log of 
the output and a backtrace, though I am not sure how useful latter is. 


$$$TEST/
blablabla

$$$TEST/Foreword
blablabla

$$$TEST/C1/
blablabla

$$$TEST/C2/
blablabla

$$$TEST/C3/
blablabla

#####################################################

TEST/
dup key, trying: TEST/ {2}
dup key, trying: TEST/ {3}
dup key, trying: TEST/ {4}
dup key, trying: TEST/ {5}
dup key, trying: TEST/ {6}
dup key, trying: TEST/ {7}
dup key, trying: TEST/ {8}
dup key, trying: TEST/ {9}
dup key, trying: TEST/ {10}
dup key, trying: TEST/ {11}
dup key, trying: TEST/ {12}
dup key, trying: TEST/ {13}
dup key, trying: TEST/ {14}
dup key, trying: TEST/ {15}
dup key, trying: TEST/ {16}
dup key, trying: TEST/ {17}
dup key, trying: TEST/ {18}
dup key, trying: TEST/ {19}
dup key, trying: TEST/ {20}
dup key, trying: TEST/ {21}

[..] # I cut out some 50000 lines here 

dup key, trying: TEST/ {58347}
dup key, trying: TEST/ {58348}
dup key, trying: TEST/ {58349}
dup key, trying: TEST/ {58350}
dup key, trying: TEST/ {58351}
dup key, trying: TEST/ {58352}
dup key, trying: TEST/ {58353}
dup key, trying: TEST/ {58354}

[..] # I pressed Ctrl-C to stop the loop here


###############################################################

(gdb) bt
#0  0x00007ffff3e141f0 in __read_nocancel () at
../sysdeps/unix/syscall-template.S:84
#1  0x000055555558228c in sword::FileDesc::read (this=0x5555558976c0,
buf=0x7fffffffdab8, count=4) at ../src/mgr/filemgr.cpp:149
#2  0x000055555558f752 in sword::TreeKeyIdx::getTreeNodeFromDatOffset
(this=0x555555897910, ioffset=0, node=0x555555897988)
    at ../src/keys/treekeyidx.cpp:345
#3  0x000055555558f9a6 in sword::TreeKeyIdx::getTreeNodeFromIdxOffset
(this=0x555555897910, ioffset=0, node=0x555555897988)
    at ../src/keys/treekeyidx.cpp:395
#4  0x000055555558ec49 in sword::TreeKeyIdx::root (this=0x555555897910)
at ../src/keys/treekeyidx.cpp:130
#5  0x00005555555900e4 in sword::TreeKeyIdx::setText
(this=0x555555897910, ikey=0x555555868630 "TEST/ {58736}")
    at ../src/keys/treekeyidx.cpp:520
#6  0x0000555555580718 in sword::SWKey::copyFrom (this=0x555555897910,
ikey=...) at ../src/keys/swkey.cpp:177
#7  0x00005555555902fb in sword::TreeKeyIdx::copyFrom
(this=0x555555897910, ikey=...) at ../src/keys/treekeyidx.cpp:552
#8  0x00005555555809c4 in sword::SWKey::positionFrom
(this=0x555555897910, ikey=...) at ../include/swkey.h:173
#9  0x00005555555ad670 in sword::SWKey::operator= (this=0x555555897910,
ikey=...) at ../include/swkey.h:227
#10 0x00005555555a621b in sword::SWModule::setKey (this=0x555555897760,
ikey=0x7fffffffdd30) at ../src/modules/swmodule.cpp:299
#11 0x0000555555580290 in sword::SWModule::setKey (this=0x555555897760,
ikey=...) at ../include/swmodule.h:235
#12 0x000055555557f4ca in writeEntry (book=0x555555897760,
keyBuffer=..., entBuffer=...) at imp2gbs.cpp:215
#13 0x000055555557f7f8 in main (argc=2, argv=0x7fffffffe058) at
imp2gbs.cpp:250



More information about the sword-devel mailing list