![]() |
【转帖】memory exception when writing many block insertions
memory exception when writing many block insertions
memory exception when writing many block insertions hi, it looks a null pointer exception when writing a dxf/dwg file with more than approx. 26000 block insertions of the same definition. the call stack shows odmemorystreamimpl<odstaticrxobject<odstreambuf>>: :addpage is where the crash occurs after a call to oddbblockreferenceptr::setblocktablerecord. it is possible to write out more than 26000 blocks, just as long as there are no more than ~26000 of one particular block type. you may be wondering how we came to writing so many blocks... in our program, these are single elevation points with symbols turned on. the workaround for our user is to turn off symbols before writing to autocad, then they get exported as autocad point entities. ps. this is dwgdirectc++ 2.04.01 thanks! erle the problem is with undo. you should add these multiple inserts inside transaction. use oddbdatabase::starttransaction(), oddbdatabase::endtransaction(). vladimir |
所有的时间均为北京时间。 现在的时间是 04:31 PM. |