dpnet: Simplify the storing of component data
leslie_alistair at hotmail.com
Thu Jun 11 03:06:00 CDT 2015
Thanks for the review.
The patch started out at fixing an issue I found in Duplicate, however
it turned into simplifying the code, thus the test you commented on.
After looking at wined3d_private_data, I see the the way it should
be handled and will provide a cleaner patch to fix the issue I found
On 10/06/15 19:17, Stefan Dösinger wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> I am OK with this patch in principle if you believe that it is an
> improvement. It reduces the code size, but on the other hand it means
> that you're having tiny allocations for DWORDs and GUIDs. Keep in mind
> that such allocations mean overhead in memory use, run time and memory
> I'd like to point out an alternative approach: You can give struct
> component a variable size, similar to how struct wined3d_private_data
> in include/wine/wined3d.h works.
> But overall I think this is a minor detail considering the overall
> state of the directplay libs and that there are more important issues
> to solve. I don't want to stand in your way by arguing about small
> things like this. I can't promise Alexandre agrees though.
> Either way, two style comments:
> The test is a good test to add, but should be in its own patch.
> Am 2015-06-10 um 06:41 schrieb Alistair Leslie-Hughes:
>> found = TRUE;
>> - if(entry->type == DPNA_DATATYPE_STRING_ANSI)
>> - heap_free(entry->data.ansi);
>> - else if(entry->type == DPNA_DATATYPE_STRING)
>> - heap_free(entry->data.string);
>> - else if(entry->type == DPNA_DATATYPE_BINARY)
>> - heap_free(entry->data.binary);
>> + heap_free(entry->data);
> The added heap_free line is indented by 11 chars.
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2
> -----END PGP SIGNATURE-----
More information about the wine-devel