Commit 1417d7e4 authored by Kevin Wolf's avatar Kevin Wolf Committed by malc
Browse files

qcow2: Silence false warning



Some gcc versions seem not to be able to figure out that the switch
statement covers all possible values and that c is therefore always
initialised. Add a default branch for them.

Reported-by: default avatarmalc <av1474@comtv.ru>
Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
Signed-off-by: default avatarmalc <av1474@comtv.ru>
parent da9fa17e
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -471,6 +471,8 @@ int qcow2_get_cluster_offset(BlockDriverState *bs, uint64_t offset,
                QCOW_OFLAG_COMPRESSED | QCOW_OFLAG_ZERO);
        *cluster_offset &= L2E_OFFSET_MASK;
        break;
    default:
        abort();
    }

    qcow2_cache_put(bs, s->l2_table_cache, (void**) &l2_table);