[Spice-devel] [PATCH spice-gtk 1/2] display: fix palette regression

Marc-André Lureau mlureau at redhat.com
Thu Oct 3 05:51:15 PDT 2013



----- Original Message -----
> On Thu, Oct 03, 2013 at 01:53:55PM +0200, Marc-André Lureau wrote:
> > palette_get() used to return a ref, and palette_release() used to
> > release that ref.
> > 
> > Since ed877341, the palette is no longer refcount'ed, since its usage is
> > exclusively local in common/canvas code.
> > 
> > palette_release() shouldn't remove the palette from the cache.
> 
> Doesn't this mean we will keep some palettes in the cache forever? If yes,
> some guarantee that the memory used by these palettes is bounded?

palette_get() / palette_release() always come in pair, so it isn't used to remove a palette. And a palette is remove from cache with SPICE_MSG_DISPLAY_INVAL_{ALL_}PALETTE


> Christophe
> 
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/spice-devel
> 


More information about the Spice-devel mailing list