gallium/u_inlines: remove the destroy variable in pipe_reference_described

Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
Tested-by: Dieter Nützel <Dieter@nuetzel-hh.de>
This commit is contained in:
Marek Olšák 2018-09-01 01:28:08 -04:00
parent ed880fe192
commit d211679017

View file

@ -74,8 +74,6 @@ pipe_reference_described(struct pipe_reference *dst,
struct pipe_reference *src,
debug_reference_descriptor get_desc)
{
boolean destroy = FALSE;
if (dst != src) {
/* bump the src.count first */
if (src) {
@ -87,14 +85,13 @@ pipe_reference_described(struct pipe_reference *dst,
if (dst) {
int count = p_atomic_dec_return(&dst->count);
assert(count != -1); /* dst had to be referenced */
if (!count)
destroy = TRUE;
debug_reference(dst, get_desc, -1);
if (!count)
return true;
}
}
return destroy;
return false;
}
static inline boolean