On Sun, Jul 01, 2012 at 02:37:39PM +0200, Lars-Peter Clausen wrote:
> On 06/30/2012 08:54 PM, Lars-Peter Clausen wrote:
> >[...]
> >
> > - new_sources = g_try_realloc(sources, sizeof(struct source) *
> > (num_sources - 1));
> > + new_pollfds = g_try_realloc(sources, sizeof(GPollFD) * num_sources);
>
> Ok, here is obviously a copy&paste error.
>
> > + if (!new_pollfds && num_sources > 0) {
> > + sr_err("session: %s: new_sources malloc failed", __func__);
> > + return SR_ERR_MALLOC;
> > + }
> > +
> > + new_sources = g_try_realloc(sources, sizeof(struct source) *
> > num_sources);
>
> And this line should have actually been in patch 1.
>
> Will fix these two in v2.
I've merged the current set for now, please post any remaining patches
on top of HEAD.
>From a quick glance the patchset looks OK in general, and it also builds
fine on Windows, and also seems to work, though I need to do more tests
here. See also Peter's comment in another mail.
Not sure about the longer-term future, I think just always using
GIOChannels is the most portable and hassle-free version, I'd avoid FDs
completely in the future, if there isn't any hard reason to use them
directly.
Anyway, thanks again for your patches! Will let you know if and how this
improves Windows support (it should quite a bit, I hope).
Uwe.
--
http://hermann-uwe.de | http://sigrok.org
http://randomprojects.org | http://unmaintained-free-software.org
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
sigrok-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sigrok-devel