Bug 31198 - Windows portability patches for telepathy-glib
Summary: Windows portability patches for telepathy-glib
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-glib (show other bugs)
Version: 0.12
Hardware: Other Windows (All)
: medium normal
Assignee: Simon McVittie
QA Contact: Telepathy bugs list
URL: http://git.collabora.co.uk/?p=user/sm...
Keywords: patch
Depends on:
Reported: 2010-10-28 07:26 UTC by Thomas Flüeli
Modified: 2010-11-01 05:12 UTC (History)
0 users

See Also:
i915 platform:
i915 features:

patch 1 (836 bytes, patch)
2010-10-28 07:26 UTC, Thomas Flüeli
Details | Splinter Review
patch 2 (1.20 KB, patch)
2010-10-28 07:27 UTC, Thomas Flüeli
Details | Splinter Review

Description Thomas Flüeli 2010-10-28 07:26:51 UTC
Created attachment 39854 [details] [review]
patch 1

I've made some changes to get telepathy-glib compile with MSVC 9.
Comment 1 Thomas Flüeli 2010-10-28 07:27:12 UTC
Created attachment 39855 [details] [review]
patch 2
Comment 2 Simon McVittie 2010-10-29 05:22:58 UTC
Review of attachment 39854 [details] [review]:

This isn't really the right fix; we should be using G_VA_COPY() instead.
Comment 3 Simon McVittie 2010-10-29 05:25:28 UTC
Review of attachment 39855 [details] [review]:

The previous implementation dynamically allocated more stack, which is meant to work, but I can see that it's not necessarily the most portable thing to do.

We prefer to use g_malloc() and g_free() instead of malloc() and free().

I'd be inclined to remove the artificial block now that we're not using it for its side-effect of letting us have more stack. I'll prepare an alternative patch.
Comment 4 Simon McVittie 2010-10-29 05:48:31 UTC
See the URL field for a branch which should hopefully also fix these; please let me know whether it works. Thanks for your patches!
Comment 5 Thomas Flüeli 2010-10-30 09:37:48 UTC
(In reply to comment #2)
> This isn't really the right fix; we should be using G_VA_COPY() instead.

Perfect, I didn't know that G_VA_COPY() exists.

Your branch looks good and works fine.
Comment 6 Simon McVittie 2010-11-01 05:12:46 UTC
Fixed in git for 0.12.3 and 0.13.4, thanks.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.