KVM: fix segment_base() error checking
authorGleb Natapov <gleb@redhat.com>
Thu, 25 Feb 2010 10:43:08 +0000 (12:43 +0200)
committerAvi Kivity <avi@redhat.com>
Sun, 25 Apr 2010 10:53:35 +0000 (13:53 +0300)
commit254d4d48a56925622a5592ad590a738735b66135
tree050e2d5e924a5423916aa79ea3d9a265b282c038
parentd6ab1ed44627c91d0a857a430b7ec4ed8648c7a5
KVM: fix segment_base() error checking

fix segment_base() to properly check for null segment selector and
avoid accessing NULL pointer if ldt selector in null.

Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
arch/x86/kvm/x86.c