]> git.proxmox.com Git - mirror_lxc.git/blobdiff - src/lxc/storage/btrfs.c
storage: constify where possible
[mirror_lxc.git] / src / lxc / storage / btrfs.c
index 29b44dfdfdf754c4de51cdd373a42fa8b5d8e7b5..47f199b940b3227e947be6e6267d210dba7dc600 100644 (file)
@@ -187,7 +187,8 @@ bool btrfs_detect(const char *path)
 int btrfs_mount(struct lxc_storage *bdev)
 {
        unsigned long mntflags;
-       char *mntdata, *src;
+       char *mntdata;
+       const char *src;
        int ret;
 
        if (strcmp(bdev->type, "btrfs"))
@@ -348,7 +349,7 @@ out:
 
 int btrfs_snapshot_wrapper(void *data)
 {
-       char *src;
+       const char *src;
        struct rsync_data_char *arg = data;
 
        if (setgid(0) < 0) {
@@ -372,7 +373,7 @@ int btrfs_clonepaths(struct lxc_storage *orig, struct lxc_storage *new,
                     const char *oldpath, const char *lxcpath, int snap,
                     uint64_t newsize, struct lxc_conf *conf)
 {
-       char *src;
+       const char *src;
 
        if (!orig->dest || !orig->src)
                return -1;
@@ -821,7 +822,7 @@ bool btrfs_try_remove_subvol(const char *path)
 
 int btrfs_destroy(struct lxc_storage *orig)
 {
-       char *src;
+       const char *src;
 
        src = lxc_storage_get_path(orig->src, "btrfs");