From eaac013b4e68dea48fb2c3070b7c7ca59dfd1b96 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Tue, 17 Jul 2012 15:14:14 +0100 Subject: Hack asdcplib to make its RNG repeatable when we are testing. --- src/util.cc | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) (limited to 'src/util.cc') diff --git a/src/util.cc b/src/util.cc index aab2e184..e805f3eb 100644 --- a/src/util.cc +++ b/src/util.cc @@ -28,8 +28,6 @@ using namespace std; -bool libdcp::libdcp_test = false; - /** Create a UUID. * @return UUID. */ @@ -38,20 +36,7 @@ libdcp::make_uuid () { char buffer[64]; Kumu::UUID id; - - if (libdcp_test) { - static int N = 0; - byte_t t[16]; - for (int i = 0; i < 16; ++i) { - t[i] = N; - } - ++N; - - id = Kumu::UUID (t); - } else { - Kumu::GenRandomValue (id); - } - + Kumu::GenRandomValue (id); id.EncodeHex (buffer, 64); return string (buffer); } -- cgit v1.2.3