]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
document things changed so far.
authorNathan Scott <nathans@sgi.com>
Sun, 19 Aug 2001 09:59:52 +0000 (09:59 +0000)
committerNathan Scott <nathans@sgi.com>
Sun, 19 Aug 2001 09:59:52 +0000 (09:59 +0000)
doc/CHANGES
libxfs/util.c
logprint/log_misc.c
mkfs/proto.c

index 7fcc1bef1169e12b4cd7a9c519d0a1e1374d0bf8..b9fce592680538e5fa14e333f5dc3a33761ea605 100644 (file)
@@ -1,3 +1,9 @@
+xfsprogs-current
+       - fix logprint bug in reporting extended attributes
+         (thanks to Tang Lingbo <tanglb@sina.com> for fixing this)
+       - fix mkfs.xfs core dump when attemping to run on devices
+         which are too small to hold a valid XFS filesystem
+
 xfsprogs-1.3.5 (13 August 2001)
        - fix bug in xfs_db bit handling on big endian platforms
        - fix mkfs bug related to too-small final allocation group
index 74da157761af16e75b3b56badb1d357ef5b4d302..92ca72ef2f25355d3caa19f281af691e95ca1c6a 100644 (file)
@@ -61,9 +61,9 @@ libxfs_inode_alloc(
        ialloc_context = (xfs_buf_t *)0;
        error = libxfs_ialloc(*tp, pip, mode, nlink, rdev, cr, (xfs_prid_t) 0,
                           1, &ialloc_context, &call_again, &ip);
-       if (error) {
+       if (error)
                return error;
-       }
+
        if (call_again) {
                xfs_trans_bhold(*tp, ialloc_context);
                ntp = xfs_trans_dup(*tp);
@@ -78,12 +78,15 @@ libxfs_inode_alloc(
                error = libxfs_ialloc(*tp, pip, mode, nlink, rdev, cr,
                                   (xfs_prid_t) 0, 1, &ialloc_context,
                                   &call_again, &ip);
-               if (error) {
+               if (!ip)
+                       error = ENOSPC;
+               if (error)
                        return error;
-               }
        }
+       if (!ip)
+               error = ENOSPC;
+
        *ipp = ip;
-       ASSERT(ip);
        return error;
 }
 
@@ -696,7 +699,7 @@ libxfs_da_read_bufr(
        xfs_trans_t     *trans,
        xfs_inode_t     *dp,
        xfs_dablk_t     bno,
-       xfs_daddr_t             mappedbno,
+       xfs_daddr_t     mappedbno,
        xfs_dabuf_t     **bpp,
        int             whichfork)
 {
index 76d492aa4cf4d27cb1bd2d8b18cec2d92c2324bf..f98afa43b1a7fa878041b76fa5b6cad09a5005fa 100644 (file)
@@ -687,7 +687,7 @@ xlog_print_trans_inode(xfs_caddr_t *ptr, int len, int *i, int num_ops)
     *ptr += sizeof(xfs_dinode_core_t);
 
     if (*i == num_ops-1 && f->ilf_size == 3)  {
-           return 1;
+       return 1;
     }
 
     /* does anything come next */
@@ -724,8 +724,45 @@ xlog_print_trans_inode(xfs_caddr_t *ptr, int len, int *i, int num_ops)
                xlog_print_dir_sf((xfs_dir_shortform_t*)*ptr, size);
            }
            *ptr += INT_GET(op_head->oh_len, ARCH_CONVERT);
-           if (XLOG_SET(op_head->oh_flags, XLOG_CONTINUE_TRANS))
+           if (XLOG_SET(op_head->oh_flags, XLOG_CONTINUE_TRANS)) {
+               return 1;
+           }
+           break;
+       }
+       case XFS_ILOG_AEXT: {
+           ASSERT(f->ilf_size == 3);
+           (*i)++;
+           xlog_print_op_header(op_head, *i, ptr);
+           printf("EXTENTS inode attr\n");
+           *ptr += INT_GET(op_head->oh_len, ARCH_CONVERT);
+           if (XLOG_SET(op_head->oh_flags, XLOG_CONTINUE_TRANS))  {
+               return 1;
+           }
+           break;
+       }
+       case XFS_ILOG_ABROOT: {
+           ASSERT(f->ilf_size == 3);
+           (*i)++;
+           xlog_print_op_header(op_head, *i, ptr);
+           printf("BTREE inode attr\n");
+           *ptr += INT_GET(op_head->oh_len, ARCH_CONVERT);
+           if (XLOG_SET(op_head->oh_flags, XLOG_CONTINUE_TRANS))  {
+               return 1;
+           }
+           break;
+       }
+       case XFS_ILOG_ADATA: {
+           ASSERT(f->ilf_size == 3);
+           (*i)++;
+           xlog_print_op_header(op_head, *i, ptr);
+           printf("LOCAL inode attr\n");
+           if (mode == IFDIR) {
+               xlog_print_dir_sf((xfs_dir_shortform_t*)*ptr, size);
+           }
+           *ptr += INT_GET(op_head->oh_len, ARCH_CONVERT);
+           if (XLOG_SET(op_head->oh_flags, XLOG_CONTINUE_TRANS)) {
                return 1;
+           }
            break;
        }
        case XFS_ILOG_DEV: {
index 409557f311b12f24d1c3922574d48b7747bc57de..503fc81b2e491d6c99135d42fa3dc1cde20d3ae7 100644 (file)
@@ -113,11 +113,17 @@ fail(
        char    *msg,
        int     i)
 {
-       fprintf(stderr, "%s: %s %d\n", progname, msg, i);
-       ASSERT(0);
+       fprintf(stderr, "%s: %s [%d - %s]\n", progname, msg, i, strerror(i));
        exit(1);
 }
 
+void
+res_failed(
+       int     i)
+{
+       fail("cannot reserve space", i);
+}
+
 static void
 getres(
        xfs_trans_t     *tp,
@@ -746,15 +752,6 @@ rtinit(
        }
 }
 
-void
-res_failed(
-       int     err)
-{
-       fprintf(stderr, "%s: ran out of disk space!\n", progname);
-       ASSERT(0);
-       exit(1);
-}
-
 static long
 filesize(
        int             fd)