~ubuntu-branches/debian/sid/btrfs-tools/sid

« back to all changes in this revision

Viewing changes to cmds-rescue.c

  • Committer: Package Import Robot
  • Author(s): Dimitri John Ledkov
  • Date: 2014-04-19 12:12:11 UTC
  • mfrom: (1.3.4)
  • Revision ID: package-import@ubuntu.com-20140419121211-0jeuu83zmf9nowmu
Tags: 3.14.1-1
* New upstream release.
* Switch to git-dpm.
* Rebase and cleanup patches.

Show diffs side-by-side

added added

removed removed

Lines of Context:
80
80
        file = argv[optind];
81
81
 
82
82
        ret = check_mounted(file);
83
 
        if (ret) {
 
83
        if (ret < 0) {
 
84
                fprintf(stderr, "Could not check mount status: %s\n",
 
85
                        strerror(-ret));
 
86
                return 1;
 
87
        } else if (ret) {
84
88
                fprintf(stderr, "the device is busy\n");
85
 
                return ret;
 
89
                return 1;
86
90
        }
87
91
 
88
92
        ret = btrfs_recover_chunk_tree(file, verbose, yes);
133
137
 
134
138
        dname = argv[optind];
135
139
        ret = check_mounted(dname);
136
 
        if (ret) {
 
140
        if (ret < 0) {
 
141
                fprintf(stderr, "Could not check mount status: %s\n",
 
142
                        strerror(-ret));
 
143
                return 1;
 
144
        } else if (ret) {
137
145
                fprintf(stderr, "the device is busy\n");
138
146
                return 1;
139
147
        }