Remove run-as compat wrapper from internal code
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 20 Oct 2016 15:38:31 +0000 (11:38 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 20 Oct 2016 15:38:31 +0000 (11:38 -0400)
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-sessiond/ust-registry.c
src/common/runas.h
src/common/ust-consumer/ust-consumer.c

index 6913487d5611aef301313668612d70370d25d5b8..3c3aa91f02ce1b0a4719bdc982af80e22bc3fd8c 100644 (file)
@@ -994,7 +994,7 @@ void ust_registry_session_destroy(struct ust_registry_session *reg)
                /*
                 * Try deleting the directory hierarchy.
                 */
-               (void) run_as_recursive_rmdir(reg->root_shm_path,
+               (void) run_as_rmdir_recursive(reg->root_shm_path,
                                reg->uid, reg->gid);
        }
        /* Destroy the enum hash table */
index ac1143eecf84100f3f3444b288a04ba06860bb33..46d4502e9c781a387f4723123f634167fe2a11ff 100644 (file)
@@ -34,12 +34,6 @@ int run_as_unlink(const char *path, uid_t uid, gid_t gid);
 LTTNG_HIDDEN
 int run_as_rmdir_recursive(const char *path, uid_t uid, gid_t gid);
 
-/* Backward compat. */
-static inline int run_as_recursive_rmdir(const char *path, uid_t uid, gid_t gid)
-{
-       return run_as_rmdir_recursive(path, uid, gid);
-}
-
 LTTNG_HIDDEN
 int run_as_create_worker(char *procname);
 LTTNG_HIDDEN
index 01d5ecf6505cc0667a41194d5cb1f07d06e3540b..76eee2ad9f56d448a9f5c9913cd86685b0279e8c 100644 (file)
@@ -510,7 +510,7 @@ error_open:
        }
        /* Try to rmdir all directories under shm_path root. */
        if (channel->root_shm_path[0]) {
-               (void) run_as_recursive_rmdir(channel->root_shm_path,
+               (void) run_as_rmdir_recursive(channel->root_shm_path,
                                channel->uid, channel->gid);
        }
        free(stream_fds);
@@ -2067,7 +2067,7 @@ void lttng_ustconsumer_free_channel(struct lttng_consumer_channel *chan)
        ustctl_destroy_channel(chan->uchan);
        /* Try to rmdir all directories under shm_path root. */
        if (chan->root_shm_path[0]) {
-               (void) run_as_recursive_rmdir(chan->root_shm_path,
+               (void) run_as_rmdir_recursive(chan->root_shm_path,
                                chan->uid, chan->gid);
        }
        free(chan->stream_fds);
This page took 0.027967 seconds and 4 git commands to generate.