CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Guest

    How to allocate space in a thread?

    I wander how to allocate space in a thread created using
    AfxBeginThread(pFunc,param)?

    I ever use the malloc function,sometimes it works,Otherwise
    it will invoke a error.

    It seems that no error occur if i use GlobalAlloc() function .
    But I don't know the reason.

    Who can tell me what on earth is the proper method to allocate
    space dynamically in a thread?

    I look forward to your response, thanks a lot!




  2. #2
    Join Date
    May 1999
    Location
    Sydney, Australia
    Posts
    420

    Re: How to allocate space in a thread?

    new() is the way to go

    Sally


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured