s390: Fix buggy assignment

nd->model keeps dynamically allocated model names.
So casting of a constant string is wrong here.

Signed-off-by: Stefan Weil <weil@mail.berlios.de>
Acked-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
This commit is contained in:
Stefan Weil 2009-12-14 10:39:12 +01:00 committed by Aurelien Jarno
parent 73642f5bdb
commit 5a2b3fc5aa
1 changed files with 1 additions and 1 deletions

View File

@ -209,7 +209,7 @@ static void s390_init(ram_addr_t ram_size,
DeviceState *dev;
if (!nd->model) {
nd->model = (char*)"virtio";
nd->model = qemu_strdup("virtio");
}
if (strcmp(nd->model, "virtio")) {