~ubuntu-branches/ubuntu/maverick/ocfs2-tools/maverick

« back to all changes in this revision

Viewing changes to libocfs2/mkjournal.c

  • Committer: Bazaar Package Importer
  • Author(s): Fabio M. Di Nitto
  • Date: 2007-11-19 06:53:59 UTC
  • Revision ID: james.westby@ubuntu.com-20071119065359-7yan1p3eg1d28sgx
Tags: 1.3.9-0ubuntu1

* Update default timeouts in template and translations files.

* debian/rules: fix clean target to not purge upstream patches/ directory.

* debian/control: rework Build-Depends
  - sort them: debian build specific bits first, upstream after in configure
    check order.
  - add pkg-config.
  - add libselinux1-dev and libsepol1-dev.

* add package ocfs2-tools-static-dev to include all development headers and
  static libraries required to build ocfs2-test (and possibly other tools
  that already in development stage.

* stop shipping local copy of mount.ocfs2.8

Show diffs side-by-side

added added

removed removed

Lines of Context:
217
217
        uint64_t offset = 0;
218
218
        uint32_t wrote, count, jrnl_blocks;
219
219
 
220
 
        ret = ocfs2_extent_map_init(fs, ci);
221
 
        if (ret)
222
 
                goto out;
223
 
 
224
220
#define BUFLEN  1048576
225
221
        ret = ocfs2_malloc_blocks(fs->fs_io, (BUFLEN >> bs_bits), &buf);
226
222
        if (ret)
243
239
                goto out;
244
240
 
245
241
        /* re-use offset here for 1st journal block. */
246
 
        ret = ocfs2_extent_map_get_blocks(ci, 0, 1, &offset, NULL);
 
242
        ret = ocfs2_extent_map_get_blocks(ci, 0, 1, &offset, NULL, NULL);
247
243
        if (ret)
248
244
                goto out;
249
245
 
301
297
                ret = ocfs2_write_inode(fs, blkno, (char *)di);
302
298
                if (ret)
303
299
                        goto out;
 
300
        } else if (clusters < di->i_clusters) {
 
301
                uint64_t new_size = clusters <<
 
302
                           OCFS2_RAW_SB(fs->fs_super)->s_clustersize_bits;
 
303
                ret = ocfs2_truncate(fs, blkno, new_size);
 
304
                if (ret)
 
305
                        goto out;
 
306
 
 
307
                ocfs2_free_cached_inode(fs, ci);
 
308
                ret = ocfs2_read_cached_inode(fs, blkno, &ci);
 
309
                if (ret) {
 
310
                        ci = NULL;
 
311
                        goto out;
 
312
                }
304
313
        }
305
314
 
306
315
        ret = ocfs2_format_journal(fs, ci);