nvme: Fix unintentional integer overflow (OVERFLOW_BEFORE_WIDEN)
commit2115f2a1d8c77c2a735add1ed02ae0c1feae0d9a
authorStefan Weil <sw@weilnetz.de>
Sat, 14 Mar 2015 16:00:44 +0000 (14 17:00 +0100)
committerStefan Hajnoczi <stefanha@redhat.com>
Fri, 27 Mar 2015 10:01:12 +0000 (27 10:01 +0000)
tree2949823072ed214228034c99c6d3af485a8273a9
parent4ad9e2b36e1e00fe5b96c3448ecd673e11c4d6d8
nvme: Fix unintentional integer overflow (OVERFLOW_BEFORE_WIDEN)

The shift operation on nlb gives a 32 bit result if no type cast is
applied. This bug was reported by Coverity.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
Message-id: 1426348844-8793-1-git-send-email-sw@weilnetz.de
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
hw/block/nvme.c