Re: Operator new failing in windows after several days of operation

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



More info/answering questions from other posts:

>To reiterate points you've made in other posts in this thread:
>
>1. You're using VC6 with SP5.
>2. You're using boost
>3. You're using the STL
>4. Your program uses several (11) threads
>5. You see a crash which might be explained by heap corruption after 3 days
>of heavy load.

6. The application is broken up into 1 MFC application and 10-20
dynamically loaded DLLs.
7. All DLLs link to the Multithreadded DLL runtime in the compiler
settings
8. There is a mix of MFC extension and NON-MFC DLLs

>Questions:
>1. Are you linking with thrownew.obj? If not, you have a non-conforming
>implementation of ::operator new(). See
>http://msdn.microsoft.com/msdnmag/issues/03/09/LegacySTLFix/default.aspx for
>a thorough discussion.

No. I am doing nothing more than linking to the multithreadded DLL
runtime. I will investigate your link furthur.

>2. Are you using the VC version of the STL, and if so, have you applied all
>of the patches found at http://www.dinkumware.com/vc_fixes.html?

Were currently only using the ones for XMEMORY, XSTRING, and XTREE,
because those were the only ones that seemed to apply to our
application.

>3. What are your compiler and linker settings?

compiler options:
/nologo /MDd /W3 /Gm /GR /GX /Zi /Od /I

..exe linker options:
winmm.lib boost_threadd.lib kernel32.lib version.lib /nologo
/subsystem:windows /incremental:yes /pdb:"../Debug/Sts.pdb"
/map:"Debug/Sts.map" /debug /machine:I386 /out:"../Debug/Sts.exe"
/pdbtype:sept /libpath:"../debug"

..dll linker options:
boost_threadd.lib /nologo /base:"0x02B00000" /dll /incremental:yes
/pdb:"../Debug/Rdts.pdb" /map:"Debug/Rdts.map" /debug /machine:I386
/out:"../Debug/Rdts.dll" /implib:"../Debug/Rdts.lib" /pdbtype:sept
/libpath:"../debug"

I only included one of the dlls. the rest all all very similar, with
differing perferred load addresses, etc.

>4. Is the program a monolithic EXE, or is it broken into one or more DLLs?
>If so, what are the compiler and linker settings for the DLLs?

Many dlls. I can post them all, if you think it would help, but it
would be quite verbose. Would you like me to do so?

-Adrian
.



Relevant Pages

  • Re: Operator new failing in windows after several days of operation
    ... > I've been trying to track down a possible heap corruption/operator new ... Is the program a monolithic EXE, or is it broken into one or more DLLs? ... what are the compiler and linker settings for the DLLs? ...
    (microsoft.public.vc.language)
  • Passing a structure to a C dll in VB .NET
    ... I have read several interesting posts on passing structures to C dlls, but none seem to cover the following case. ... Steve ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Overview
    ... You claimed that DLLS were a universal feature. ... the only reason you are not in my killfile is ... _specifically_ so that I can read your posts and point out any errors ...
    (comp.lang.c)
  • Re: [Xnews] Formatted Font
    ... Or am I missing something obvious? ... you didn't show us the versions of the DLLs. ... know where it's getting its copy of RICHED32. ... Killing all posts from Google Groups ...
    (news.software.readers)
  • RE: Where is CryptExportPKCS8Ex() ?
    ... I have tried strings.exe from sysinternals to search all the dlls in ... When responding to posts, please "Reply to Group" via your newsreader so ...
    (microsoft.public.platformsdk.security)