46e46fa mkfs.gfs2: Make sure the last rg_skip is 0

Authored and Committed by andyp 3 years ago
    mkfs.gfs2: Make sure the last rg_skip is 0
    
    The rg_skip field of the last resource group is meant to be zero. Ensure
    that gfs2_grow and mkfs.gfs2 set it that way once the resource groups
    have been written, using a new lgfs2_rgrps_write_final() function that
    is called once we know that there are no more resource groups to write.
    
    Tests included, which required adding code to create temporary sparse
    files for unit tests to use.
    
    Signed-off-by: Andrew Price <anprice@redhat.com>
    
        
file modified
+58 -12
file modified
+1 -0
file modified
+18 -1
file modified
+4 -0
file modified
+4 -1
file modified
+8 -1