~xnox/ubuntu/quantal/lvm2/merge95

« back to all changes in this revision

Viewing changes to lib/commands/toolcontext.c

  • Committer: Dmitrijs Ledkovs
  • Date: 2012-08-15 09:45:58 UTC
  • Revision ID: dmitrijs.ledkovs@canonical.com-20120815094558-1fugetlxzs49g6g9
quilt push

Show diffs side-by-side

added added

removed removed

Lines of Context:
827
827
 
828
828
        if (cache_dir || cache_file_prefix) {
829
829
                if (dm_snprintf(cache_file, sizeof(cache_file),
830
 
                    "%s%s%s/%s.cache",
831
 
                    cache_dir ? "" : cmd->system_dir,
832
 
                    cache_dir ? "" : "/",
833
 
                    cache_dir ? : DEFAULT_CACHE_SUBDIR,
 
830
                    "%s/%s.cache",
 
831
                    cache_dir ? : DEFAULT_RUN_DIR,
834
832
                    cache_file_prefix ? : DEFAULT_CACHE_FILE_PREFIX) < 0) {
835
833
                        log_error("Persistent cache filename too long.");
836
834
                        f3->destroy(f3);
838
836
                }
839
837
        } else if (!(dev_cache = find_config_tree_str(cmd, "devices/cache", NULL)) &&
840
838
                   (dm_snprintf(cache_file, sizeof(cache_file),
841
 
                                "%s/%s/%s.cache",
842
 
                                cmd->system_dir, DEFAULT_CACHE_SUBDIR,
 
839
                                "%s/%s.cache",
 
840
                                DEFAULT_RUN_DIR,
843
841
                                DEFAULT_CACHE_FILE_PREFIX) < 0)) {
844
842
                log_error("Persistent cache filename too long.");
845
843
                f3->destroy(f3);