[PATCH v2] mpr: Implement WNetClearConnections().

Dmitry Timoshkov dmitry at baikal.ru
Thu Sep 13 01:59:26 CDT 2018


Pierre Schweitzer <pierre at reactos.org> wrote:

> > There is no need to initialize count, you are not verifying it anyway
> > after the API call.
> 
> I do use it after the API call (see the for loop).
> And it's needed to initialize it as it is an IN/OUT parameter (specifies
> how many entries you want).
...
> > Since you are using an arbitrary size for NETRESOURCEW array it should be
> > possible to avoid dynamic heap allocation by using a fixed size array of
> > NETRESOURCEW structures (say 16), or even a single item. That would simplify
> > the code.
> 
> It's not possible. NETRESOURCEW is a dynamic length structure. Its
> strings are append at the end of the structure.

I see, thanks for the clarification.

-- 
Dmitry.



More information about the wine-devel mailing list