From eb31ef3a0e5e7c3b4029a3c2e124d2df646f10a2 Mon Sep 17 00:00:00 2001 From: James Peach Date: Wed, 10 May 2006 22:33:10 +0000 Subject: [PATCH] r15529: Initialise our saved uid and gid so that we can tell when we created the profiling shmem segment and don't bogusly refuse to look at it. --- source/profile/profile.c | 8 ++++++-- source/utils/status.c | 1 + 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/source/profile/profile.c b/source/profile/profile.c index bacf00eb017..ba9596301c6 100644 --- a/source/profile/profile.c +++ b/source/profile/profile.c @@ -158,8 +158,12 @@ BOOL profile_setup(BOOL rdonly) return False; } - if (shm_ds.shm_perm.cuid != sec_initial_uid() || shm_ds.shm_perm.cgid != sec_initial_gid()) { - DEBUG(0,("ERROR: we did not create the shmem (owned by another user)\n")); + if (shm_ds.shm_perm.cuid != sec_initial_uid() || + shm_ds.shm_perm.cgid != sec_initial_gid()) { + DEBUG(0,("ERROR: we did not create the shmem " + "(owned by another user, uid %u, gid %u)\n", + shm_ds.shm_perm.cuid, + shm_ds.shm_perm.cgid)); return False; } diff --git a/source/utils/status.c b/source/utils/status.c index bc26be1ec93..05075da444f 100644 --- a/source/utils/status.c +++ b/source/utils/status.c @@ -622,6 +622,7 @@ static int traverse_sessionid(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf, vo POPT_TABLEEND }; + sec_init(); load_case_tables(); setup_logging(argv[0],True);