]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/blobdiff - repair/phase7.c
xfs: better xfs_trans_alloc interface
[thirdparty/xfsprogs-dev.git] / repair / phase7.c
index 3e234b980ce8750ebebf0ecc6d720b755d434d98..8bce117d3d38bec9645f0fe8479e91ff3186c60d 100644 (file)
@@ -40,10 +40,8 @@ update_inode_nlinks(
        int                     dirty;
        int                     nres;
 
-       tp = libxfs_trans_alloc(mp, XFS_TRANS_REMOVE);
-
        nres = no_modify ? 0 : 10;
-       error = -libxfs_trans_reserve(tp, &M_RES(mp)->tr_remove, nres, 0);
+       error = -libxfs_trans_alloc(mp, &M_RES(mp)->tr_remove, nres, 0, 0, &tp);
        ASSERT(error == 0);
 
        error = -libxfs_trans_iget(mp, tp, ino, 0, 0, &ip);