|
From: Hossein H. <ult...@em...> - 2003-07-27 11:06:43
|
Dear Christian,
> ich want to write a component to share data (PVOID) between threads.
>
> I have a class defined like the following:
>
> class CDataExchange
> {
> Public:
> stuff....
> private:
> PVOID pDataArray[1000];
> };
>
>
> in the AddData member I look the number of entrys and reallocate memmory for
> that pointer
>
> realloc(pDataArry[n], nDataLength);
Why don't you use Loki::SmartPtr<>, or boost::shared_ptr<>? There,
these issues are all solved in far days before.
Regards,
--Hossein
--
__________________________________________________________
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup
CareerBuilder.com has over 400,000 jobs. Be smarter about your job search
http://corp.mail.com/careers
|