From 9246896f7778bc8002b08a36d004854bf1426fbf Mon Sep 17 00:00:00 2001 From: Nicolas George Date: Mon, 16 Apr 2012 12:17:51 +0200 Subject: parseutils: add FATE test. --- libavutil/parseutils.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'libavutil') diff --git a/libavutil/parseutils.c b/libavutil/parseutils.c index df737f6852..eae5584a92 100644 --- a/libavutil/parseutils.c +++ b/libavutil/parseutils.c @@ -31,6 +31,13 @@ #include "random_seed.h" #include "parseutils.h" +#ifdef TEST + +#define av_get_random_seed av_get_random_seed_deterministic +static uint32_t av_get_random_seed_deterministic(void); + +#endif + int av_parse_ratio(AVRational *q, const char *str, int max, int log_offset, void *log_ctx) { @@ -677,6 +684,13 @@ int av_find_info_tag(char *arg, int arg_size, const char *tag1, const char *info #ifdef TEST +static uint32_t random = MKTAG('L','A','V','U'); + +static uint32_t av_get_random_seed_deterministic(void) +{ + return random = random * 1664525 + 1013904223; +} + #undef printf int main(void) -- cgit v1.2.3