]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit
mkfs.xfs: fix fd validity check in get_topology
authorChristoph Hellwig <hch@lst.de>
Sun, 31 Jan 2010 08:57:46 +0000 (09:57 +0100)
committerChristoph Hellwig <hch@lst.de>
Sun, 31 Jan 2010 08:57:46 +0000 (09:57 +0100)
commit85112c3a23927f299f04c193f5924249d7dd80bf
treeadc903afa72b65b8d25d646b3a09bba40405e950
parent5c911228604b411a8995327e5a35b10938a4bc06
mkfs.xfs: fix fd validity check in get_topology

Only negatie return values from open mean we failed to open the device.
Without this check we do not print the usage message when no device is
specified.  This leads to a weird failure in xfstests 122.

Reviewed-by: Eric Sandeen <sandeen@sandeen.ent>
Signed-off-by: Christoph Hellwig <hch@lst.de>
mkfs/xfs_mkfs.c