Re: How to PostMessage with a string parameter?

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

From: Igor Tandetnik (itandetnik_at_mvps.org)
Date: 12/08/04


Date: Wed, 8 Dec 2004 13:55:29 -0500


"Martin Ortiz" <martinortiz@optonline.com> wrote in message
news:eVIOVSV3EHA.1152@TK2MSFTNGP14.phx.gbl
> How do I post a message with a string parameter?

You can allocate a buffer on the heap and send the pointer cast to
WPARAM or LPARAM. The recepient will have to free the memory.

-- 
With best wishes,
    Igor Tandetnik
With sufficient thrust, pigs fly just fine. However, this is not 
necessarily a good idea. It is hard to be sure where they are going to 
land, and it could be dangerous sitting under them as they fly 
overhead. -- RFC 1925 


Relevant Pages

  • Re: memory fragmentation
    ... My application have to allocate small buffer for sending data ... I doubt the heap algorithms are O, but I also doubt they are O. ...
    (microsoft.public.vc.language)
  • Re: Inline Assembly - Runtime Stack Allocation
    ... > not allocate it on the heap. ... think of it, since you're using this space only as a transfer buffer, ...
    (comp.lang.c)
  • Re: Runtime stack allocation
    ... I'd rather not waste space or dynamically allocate on the heap (since ... //INLINED (Intel p4 assembly) ... //do some stuff with the temporary buffer, ...
    (comp.lang.c)
  • Re: Kernel malloc/realloc?
    ... No, it can't guarantees that the memory is not moved in physical, because as ... If you alloc 4K then you grow the buffer, no coppy will be made, this is my ... Even better, on application side, you can allways allocate multiples of 4K ...
    (microsoft.public.development.device.drivers)
  • [EXPL] Smail preparse_address_1() Heap Overflow
    ... The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com ... There is a heap buffer overflow, ... ssize_t Send(int s, const void *buf, size_t len, int flags) ...
    (Securiteam)