Re: [PATCH 4/6] vbox: Handle different array representations of XPCOM and MSCOM

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2010/12/17 Eric Blake <eblake@xxxxxxxxxx>:
> On 12/17/2010 11:56 AM, Matthias Bolte wrote:
>> Add a vboxArray to hide the details from the general driver code.
>> ---
>> Âsrc/vbox/vbox_MSCOMGlue.c Â| Â107 +++++++++++
>> Âsrc/vbox/vbox_MSCOMGlue.h Â| Â 15 ++
>> Âsrc/vbox/vbox_XPCOMCGlue.c | Â115 ++++++++++++
>> Âsrc/vbox/vbox_XPCOMCGlue.h | Â 14 ++
>> Âsrc/vbox/vbox_tmpl.c    | Â445 +++++++++++++++++++-------------------------
>> Â5 files changed, 447 insertions(+), 249 deletions(-)
>>
>> diff --git a/src/vbox/vbox_MSCOMGlue.c b/src/vbox/vbox_MSCOMGlue.c
>> index 81a2c99..ded1275 100644
>> --- a/src/vbox/vbox_MSCOMGlue.c
>> +++ b/src/vbox/vbox_MSCOMGlue.c
>> @@ -647,3 +647,110 @@ void
>> ÂVBoxCGlueTerm(void)
>> Â{
>> Â}
>> +
>> +
>> +
>> +/*
>> + * In MSCOM an array is represented by a SAFEARRAY pointer. To access the items
>> + * in the array the SafeArrayAccessData function is used to lock the array and
>> + * get its contents. When the items aren't needed anymore the
>> + * SafeArrayUnaccessData function is used to unlock the array. The pointer
>> + * retuned by SafeArrayAccessData function get's invalid. Finally the
>
> s/get's/becomes/
>
>> + * SafeArrayDestroy function is called to destroy the array, it also releases
>> + * or frees all items in the array according to their type.
>> + */
>> +
>> +typedef HRESULT __stdcall (*SaveArrayGetter)(void *self, SAFEARRAY **array);
>> +typedef HRESULT __stdcall (*SaveArrayGetterWithArg)(void *self, void *arg, SAFEARRAY **array);
>
> Perhaps s/SaveArrayGetter/SafeArrayGetter/g?
>
> But it looks like a good wrapper, as well as a mechanical change to
> implement its use.
>
> ACK.
>

I addressed the two comments and pushed it, thanks.

Matthias

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]