Use losetup -j to find already assigned loop device, instead of manually parsing losetup -a output (which have changed between fc13 and fc18).