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. Windows API
  4. Memory leak

Memory leak

Scheduled Pinned Locked Moved Windows API
performancetutorial
3 Posts 3 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.
  • A Offline
    A Offline
    anithavikram manisha
    wrote on last edited by
    #1

    HI, A::a (EStationID eStnID, VARIANT *pvtConTypes) { ::CComSafeArray csaConType; CComVariant varContTypes; csaConType.CreateOneDim(VT_BSTR,4); CComBSTR bstrName("Sim_Model1"); CComBSTR bstrName1("Sim_Model2"); CComBSTR bstrName2("Sim_Model3"); CComBSTR bstrName3("Sim_Model4"); csaConType.PutElement((long)0,bstrName.Copy()); csaConType.PutElement(1,bstrName1.Copy()); csaConType.PutElement(2,bstrName2.Copy()); csaConType.PutElement(3,bstrName3.Copy()); *pvtConTypes = csaConType.Detach(); can anyone please tell whether memory leak will occur in this code how to solve it

    J P 2 Replies Last reply
    0
    • A anithavikram manisha

      HI, A::a (EStationID eStnID, VARIANT *pvtConTypes) { ::CComSafeArray csaConType; CComVariant varContTypes; csaConType.CreateOneDim(VT_BSTR,4); CComBSTR bstrName("Sim_Model1"); CComBSTR bstrName1("Sim_Model2"); CComBSTR bstrName2("Sim_Model3"); CComBSTR bstrName3("Sim_Model4"); csaConType.PutElement((long)0,bstrName.Copy()); csaConType.PutElement(1,bstrName1.Copy()); csaConType.PutElement(2,bstrName2.Copy()); csaConType.PutElement(3,bstrName3.Copy()); *pvtConTypes = csaConType.Detach(); can anyone please tell whether memory leak will occur in this code how to solve it

      J Offline
      J Offline
      Jonathan Darka
      wrote on last edited by
      #2

      Please post on the correct forum, this one is for Windows Vista specific problems. regards,


      Jonathan Wilkes Darka[Xanya.net]

      1 Reply Last reply
      0
      • A anithavikram manisha

        HI, A::a (EStationID eStnID, VARIANT *pvtConTypes) { ::CComSafeArray csaConType; CComVariant varContTypes; csaConType.CreateOneDim(VT_BSTR,4); CComBSTR bstrName("Sim_Model1"); CComBSTR bstrName1("Sim_Model2"); CComBSTR bstrName2("Sim_Model3"); CComBSTR bstrName3("Sim_Model4"); csaConType.PutElement((long)0,bstrName.Copy()); csaConType.PutElement(1,bstrName1.Copy()); csaConType.PutElement(2,bstrName2.Copy()); csaConType.PutElement(3,bstrName3.Copy()); *pvtConTypes = csaConType.Detach(); can anyone please tell whether memory leak will occur in this code how to solve it

        P Offline
        P Offline
        Paul Conrad
        wrote on last edited by
        #3

        What does this have to do with Vista? This forum is specific for Vista problems and not programming problems, unless they are directly related to Vista.

        "Any sort of work in VB6 is bound to provide several WTF moments." - Christian Graus

        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