From d12b5b2f135aade4099f4b26b0fe678656158c13 Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Thu, 17 Mar 2016 19:13:17 +0100 Subject: build: Split test programs off into separate files This avoids spurious library rebuilds when only the test program code is changed and simplifies the build system. --- libavutil/fifo.c | 34 ---------------------------------- 1 file changed, 34 deletions(-) (limited to 'libavutil/fifo.c') diff --git a/libavutil/fifo.c b/libavutil/fifo.c index dffaf54533..a42899c2b3 100644 --- a/libavutil/fifo.c +++ b/libavutil/fifo.c @@ -131,37 +131,3 @@ void av_fifo_drain(AVFifoBuffer *f, int size) f->rptr -= f->end - f->buffer; f->rndx += size; } - -#ifdef TEST - -int main(void) -{ - /* create a FIFO buffer */ - AVFifoBuffer *fifo = av_fifo_alloc(13 * sizeof(int)); - int i, j, n; - - /* fill data */ - for (i = 0; av_fifo_space(fifo) >= sizeof(int); i++) - av_fifo_generic_write(fifo, &i, sizeof(int), NULL); - - /* peek at FIFO */ - n = av_fifo_size(fifo) / sizeof(int); - for (i = -n + 1; i < n; i++) { - int *v = (int *)av_fifo_peek2(fifo, i * sizeof(int)); - printf("%d: %d\n", i, *v); - } - printf("\n"); - - /* read data */ - for (i = 0; av_fifo_size(fifo) >= sizeof(int); i++) { - av_fifo_generic_read(fifo, &j, sizeof(int), NULL); - printf("%d ", j); - } - printf("\n"); - - av_fifo_free(fifo); - - return 0; -} - -#endif -- cgit v1.2.1