Merge of master-melb:xfs-cmds:31022a by kenmcd.
Add support for sb_bad_features2 in superblock structure
cprog=$tmp.get_structs.c
oprog=$tmp.get_structs
+progout=$tmp.output
cat >$cprog <<EOF
#include <stdio.h>
# create and run program
cc -o $oprog $cprog
-eval $oprog | LC_COLLATE=POSIX sort | _type_size_filter
+$oprog | _type_size_filter > $progout
+
+#
+# add addition sizes and xfs_sb_t fields that don't exist in the version
+# being tested.
+#
+
+# xfsprogs 2.9.8: sb_bad_features2 in pv 978822
+if [ $XFSPROGS_VERSION -lt 20908 ]; then
+ echo 'offsetof(xfs_sb_t, sb_bad_features2 ) = 204' >>$progout
+fi
+
+LC_COLLATE=POSIX sort $progout
status=0
offsetof(xfs_sb_t, sb_agblklog ) = 124
offsetof(xfs_sb_t, sb_agblocks ) = 84
offsetof(xfs_sb_t, sb_agcount ) = 88
+offsetof(xfs_sb_t, sb_bad_features2 ) = 204
offsetof(xfs_sb_t, sb_blocklog ) = 120
offsetof(xfs_sb_t, sb_blocksize ) = 4
offsetof(xfs_sb_t, sb_dblocks ) = 8