[Spice-devel] [PATCH xf86-video-qxl v2] Revise the XSpice audio processing to avoid the use of pthreads.

Jeremy White jwhite at codeweavers.com
Wed Oct 22 08:15:57 PDT 2014


On 10/22/2014 09:38 AM, Christophe Fergeau wrote:
> Hey,
>
> There are a bunch of calloc/malloc throughout the patch with no check
> for a NULL return, would be nice to add that.

Hmm.  I've seen this argued both ways.  One side argues that if an 
allocation is never expected to fail, that it's best to just trigger the 
resulting crash as a diagnostic.  Trying to 'handle' an error where 
there is no reasonable response can just mask the problem, or so goes 
the rationale.  And these are all small allocs that really should never 
fail.

The code base is unclear; it seems that allocs are sometimes checked, 
and sometimes not.  It's easy to add; if you feel it's the preferred 
Spice standard, I'll add the checks.


> This also adds inotify monitoring, do we need to add a check for it to
> configure.ac? (eg a check for sys/inotify.h)

I don't see how it could hurt; I'll add a check tot he XSpice section.

>
> One small note below for a typo, looks good to me apart from this.

Great, thanks.

Cheers,

Jeremy



More information about the Spice-devel mailing list