From 77b32b73ed31f9aaa6c1e476c9a041399a35be9d Mon Sep 17 00:00:00 2001 From: Stefano Sabatini Date: Thu, 2 Jun 2011 16:26:55 +0200 Subject: lavfi: apply misc style fixes Adopt K&R style for overall consistency/readability. --- libavfilter/avfilter.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'libavfilter/avfilter.c') diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c index 72e0a87f8e..b7ad6f0503 100644 --- a/libavfilter/avfilter.c +++ b/libavfilter/avfilter.c @@ -77,8 +77,8 @@ static void store_in_pool(AVFilterBufferRef *ref) av_assert0(ref->buf->data[0]); - if(pool->count == POOL_SIZE){ - AVFilterBufferRef *ref1= pool->pic[0]; + if (pool->count == POOL_SIZE) { + AVFilterBufferRef *ref1 = pool->pic[0]; av_freep(&ref1->video); av_freep(&ref1->audio); av_freep(&ref1->buf->data[0]); @@ -89,9 +89,9 @@ static void store_in_pool(AVFilterBufferRef *ref) pool->pic[POOL_SIZE-1] = NULL; } - for(i=0; ipic[i]){ - pool->pic[i]= ref; + for (i = 0; i < POOL_SIZE; i++) { + if (!pool->pic[i]) { + pool->pic[i] = ref; pool->count++; break; } @@ -102,8 +102,8 @@ void avfilter_unref_buffer(AVFilterBufferRef *ref) { if (!ref) return; - if (!(--ref->buf->refcount)){ - if(!ref->buf->free){ + if (!(--ref->buf->refcount)) { + if (!ref->buf->free) { store_in_pool(ref); return; } -- cgit v1.2.3