Excel 2007 crashes on exit after QLXL call that returns an object
Posted by Dave Blob on
URL: http://quantlib.414.s1.nabble.com/Excel-2007-crashes-on-exit-after-QLXL-call-that-returns-an-object-tp5666.html
Hi -
I'm trying to upgrade our copy of QuantLib from 0.8.0 to 1.1.0.
Both the debug and release versions that I've built crash on exit if I've made a QuantLibXL call which returns an object (for Example, qlSimpleQuote(,5,5). If I don't call any QuantLib functions, or call functions that only return strings - for example qlxlVersion - excel exits normally.
To make sure this is not something specific to my environment - I built a clean windows 7 (x64) machine which only has a fresh copy of office 2007 and visual studio 2005, all fully patched. Both the 1.1 build and the current svn build still crash on exit. On my previous machine I tried VS 2008 which also failed. I've tried boost 1.42 and boost 1.47.
When I run excel from the VS2005 debugger, I get an error like:
Unhandled exception at 0x10abec61 in excel.exe: 0xC0000005:
Access violation reading location 0x10abec61.
The stack trace does not show any QuantLib calls:
14cc29c2()
ntdll.dll!77b49a91()
[Frames below may be incorrect and/or missing, no symbols loaded for ntdll.dll]
ntdll.dll!77b68f10()
ntdll.dll!77b68e5c()
kernel32.dll!76ba79f5()
> msvcr80.dll!__crtExitProcess(int status=0) Line 683 + 0xa bytes C
msvcr80.dll!doexit(int code=0, int quick=0, int retcaller=797589938) Line 584 C
msvcr80.dll!exit(int code=0) Line 398 + 0xd bytes C
EXCEL.EXE!2f8a41b2()
EXCEL.EXE!2f88fd0a()
EXCEL.EXE!2f83b610()
EXCEL.EXE!2f850ab5()
msctf.dll!75332b9b()
msctf.dll!75332b51()
msctf.dll!75332d99()
msctf.dll!75332d6d()
msctf.dll!75332d49()
EXCEL.EXE!2f850a63()
ntdll.dll!77b48133()
ntdll.dll!77b48133()
KernelBase.dll!7688491d()
KernelBase.dll!76884933()
msctf.dll!75326276()
msctf.dll!7532625c()
msctf.dll!7533fcef()
MSO.DLL!31ab7ada()
user32.dll!755c29c3()
user32.dll!755c29a6()
EXCEL.EXE!2f84ba96()
EXCEL.EXE!2f88fbcf()
user32.dll!755b6ce9()
user32.dll!755b717a()
user32.dll!755b7257()
user32.dll!755b8e0d()
user32.dll!755b8de4()
uxtheme.dll!737f76a5()
uxtheme.dll!737f7650()
user32.dll!755b62fa()
user32.dll!755b6d91()
user32.dll!755b6d51()
EXCEL.EXE!2f8269b5()
user32.dll!755b6d91()
user32.dll!755b6d51()
user32.dll!755b6de8()
user32.dll!755b6df3()
user32.dll!755b6df3()
user32.dll!755b9a21()
ntdll.dll!77b2f8da()
user32.dll!755b9a49()
ntdll.dll!77b2011a()
MSO.DLL!31b13f65()
MSO.DLL!31b13f09()
EXCEL.EXE!2f83e271()
EXCEL.EXE!2f826935()
user32.dll!755b62fa()
user32.dll!755b6d3a()
user32.dll!755b6ce9()
user32.dll!755c0d27()
user32.dll!755c0d4d()
MSO.DLL!31adeded()
user32.dll!755b62fa()
user32.dll!755b7316()
user32.dll!755b6ce9()
user32.dll!755b77c4()
user32.dll!755b788a()
EXCEL.EXE!2f848ec2()
EXCEL.EXE!2f848deb()
EXCEL.EXE!2f848bcb()
MSO.DLL!31aa6092()
MSO.DLL!31aa5e59()
MSO.DLL!31aa94f9()
MSO.DLL!31aa94b1()
EXCEL.EXE!2f823b60()
msvcr80.dll!_onexit(int (void)* func=0x00486c5b) Line 98 + 0x5 bytes C
msvcr80.dll!_LocaleUpdate::_LocaleUpdate(localeinfo_struct * plocinfo=0x0025f894) Line 264 + 0x5 bytes C++
msvcr80.dll!_ismbblead(unsigned int tst=797048832) Line 172 + 0xf bytes C++
EXCEL.EXE!2f823874()
kernel32.dll!76ba339a()
ntdll.dll!77b49ed2()
ntdll.dll!77b49ea5()
I noticed a thread like this a few years ago and never saw any resolution to it - is it a known bug? Any suggestions on how I might proceed - are other version of visual studio or boost known to work better?
Thanks,
Dave