ffe94a7 mkfs.gfs2: Tidy up are_you_sure()

Authored and Committed by andyp 7 years ago
    mkfs.gfs2: Tidy up are_you_sure()
    
    Coverity pointed out that the 'line' pointer was dereferenced before it
    was NULL-checked and although that wasn't a bug it highlighted this
    function's strange structure. This patch tidies it up somewhat, keeping
    in mind that the memory allocated by getline() always has to be freed
    whether it succeeds or not.
    
    Signed-off-by: Andrew Price <anprice@redhat.com>
    
        
file modified
+14 -19