Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
platform
active.directory
adsi
adsi.iis-admin
base
com_ole
complus_mts
component_svcs
database
directx
gdi
graphics_mm
internet.client
internet.server
internet.server.isapi-dev
localization
mapi
messaging
msi
mslayerforunicode
multimedia
networking
networking.ipv6
sdk_install
security
shell
telephony.tapi_2
telephony.tapi_3
telephony.tsp
telephony.wte
tools
ui
ui_shell
win_base_svcs
win16
  
 
date: Wed, 16 Nov 2005 15:52:26 +0200,    group: microsoft.public.platformsdk.com_ole        back       


SysAllocString/SysFreeString, CoTaskMemAlloc/CoTaskMemFree   
Are these functions compatible? What will happen if I create a string using 
one of these functions and destroy using a function from another pair?
date: Wed, 16 Nov 2005 15:52:26 +0200   author:   Max please@newsgroup

Re: SysAllocString/SysFreeString, CoTaskMemAlloc/CoTaskMemFree   
Max <please@newsgroup> wrote:
> Are these functions compatible?

If by "compatible" you mean "interchangeable" - no, they are not.

> What will happen if I create a string
> using one of these functions and destroy using a function from
> another pair?

Heap corruption.
-- 
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
date: Wed, 16 Nov 2005 09:58:37 -0500   author:   Igor Tandetnik

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us