From 6dc9c350bdaca48805fbd319867a0c62e79a4482 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Tue, 30 Jun 2009 10:18:04 +0200 Subject: [PATCH] Revert "libuuid: move clock state file from /var/lib to /var/run" This reverts commit ab2e7dd17f556d501d27c6b0ae2c0989d5d9dae4. The state file clock.txt should be kept in /var/lib, it should remain valid after a reboot. --- shlibs/uuid/src/gen_uuid.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/shlibs/uuid/src/gen_uuid.c b/shlibs/uuid/src/gen_uuid.c index 21034199..8497ac67 100644 --- a/shlibs/uuid/src/gen_uuid.c +++ b/shlibs/uuid/src/gen_uuid.c @@ -109,8 +109,6 @@ THREAD_LOCAL unsigned short jrand_seed[3]; #endif -#define UUID_CLOCK_STATE "/var/run/libuuid/clock" - #ifdef _WIN32 static void gettimeofday (struct timeval *tv, void *dummy) { @@ -324,7 +322,8 @@ static int get_clock(uint32_t *clock_high, uint32_t *clock_low, if (state_fd == -2) { save_umask = umask(0); - state_fd = open(UUID_CLOCK_STATE, O_RDWR|O_CREAT, 0660); + state_fd = open("/var/lib/libuuid/clock.txt", + O_RDWR|O_CREAT, 0660); (void) umask(save_umask); state_f = fdopen(state_fd, "r+"); if (!state_f) { -- 2.39.5