Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Memory Leak in ADO Connection->open()

Memory Leak in ADO Connection->open()

Scheduled Pinned Locked Moved C / C++ / MFC
c++debuggingperformancequestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    voorugonda prashanth
    wrote on last edited by
    #1

    Hi All, i have a sample ADO application when i test through Rational Purify it is showing that there is leak in raw_Open() function. please give me a suggestion where there is any leak in that? [I] Summary of all memory leaks... {65488 bytes, 676 blocks} [I] MPK: Potential memory leak of 18552 bytes from 147 blocks allocated in Connection15::Open(_bstr_t,_bstr_t,_bstr_t,long) [TestMemLeakADOConn.exe] Offset 0x00000008 referenced by 0x0279ffe0, a location in a HeapAlloc'd block Distribution of potentially leaked blocks Allocation location HeapAlloc [C:\WINDOWS\system32\KERNEL32.dll] Connection15::Open(_bstr_t,_bstr_t,_bstr_t,long) [d:\samples\testmemleakadoconn\debug\msado15.tli:367] } inline HRESULT Connection15::Open ( _bstr_t ConnectionString, _bstr_t UserID, _bstr_t Password, long Options ) { => HRESULT _hr = raw_Open(ConnectionString, UserID, Password, Options); if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this)); return _hr; } TestFunction(void) [D:\samples\TestMemLeakADOConn\test.cpp:88] m_pConn->put_ConnectionTimeout (300); => m_pConn->Open(bstrConnect, "","",-1); _CommandPtr pCmd(__uuidof(Command)); main [D:\samples\TestMemLeakADOConn\test.cpp:171] Thanks, Prashanth.v

    K 1 Reply Last reply
    0
    • V voorugonda prashanth

      Hi All, i have a sample ADO application when i test through Rational Purify it is showing that there is leak in raw_Open() function. please give me a suggestion where there is any leak in that? [I] Summary of all memory leaks... {65488 bytes, 676 blocks} [I] MPK: Potential memory leak of 18552 bytes from 147 blocks allocated in Connection15::Open(_bstr_t,_bstr_t,_bstr_t,long) [TestMemLeakADOConn.exe] Offset 0x00000008 referenced by 0x0279ffe0, a location in a HeapAlloc'd block Distribution of potentially leaked blocks Allocation location HeapAlloc [C:\WINDOWS\system32\KERNEL32.dll] Connection15::Open(_bstr_t,_bstr_t,_bstr_t,long) [d:\samples\testmemleakadoconn\debug\msado15.tli:367] } inline HRESULT Connection15::Open ( _bstr_t ConnectionString, _bstr_t UserID, _bstr_t Password, long Options ) { => HRESULT _hr = raw_Open(ConnectionString, UserID, Password, Options); if (FAILED(_hr)) _com_issue_errorex(_hr, this, __uuidof(this)); return _hr; } TestFunction(void) [D:\samples\TestMemLeakADOConn\test.cpp:88] m_pConn->put_ConnectionTimeout (300); => m_pConn->Open(bstrConnect, "","",-1); _CommandPtr pCmd(__uuidof(Command)); main [D:\samples\TestMemLeakADOConn\test.cpp:171] Thanks, Prashanth.v

      K Offline
      K Offline
      kakan
      wrote on last edited by
      #2

      Please be patient, and don't repost after just two hours. You will probably get an answer, but the answer might come from someone who is still asleep. Reposting the same question isn't a good idea.

      Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups