1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
|
socket: 0.977
semantic: 0.969
other: 0.968
assembly: 0.967
instruction: 0.964
vnc: 0.964
graphic: 0.952
boot: 0.952
device: 0.935
network: 0.933
KVM: 0.932
mistranslation: 0.926
v1.0-1172-g235fe3b crashes (opts=0x0)
C:\msys\home\User\qemu\i386-softmmu>gdb --args qemu-system-i386.exe -L ..\pc-bios
GNU gdb (GDB) 7.3
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "mingw32".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from C:\msys\home\User\qemu\i386-softmmu/qemu-system-i386.exe...
done.
(gdb) r
Starting program: C:\msys\home\User\qemu\i386-softmmu/qemu-system-i386.exe -L ..\\pc-bios
[New Thread 4724.0x1224]
Program received signal SIGSEGV, Segmentation fault.
0x004eeda6 in qemu_opt_get (opts=0x0, name=0x68a7c3 "kernel")
at qemu-option.c:545
545 QemuOpt *opt = qemu_opt_find(opts, name);
(gdb) bt
#0 0x004eeda6 in qemu_opt_get (opts=0x0, name=0x68a7c3 "kernel")
at qemu-option.c:545
#1 0x004c7166 in qemu_main (argc=3, argv=0x3e5200, envp=0x0)
at C:/msys/home/User/qemu/vl.c:3250
#2 0x004c906a in SDL_main (argc=3, argv=0x3e5200)
at C:/msys/home/User/qemu/vl.c:102
#3 0x0061dcf4 in console_main ()
#4 0x0061ddb4 in WinMain@16 ()
#5 0x006329fb in main ()
(gdb)
qemu_opt_find() doesn't check if opts is NULL or not before use.
The patch fixes that issue.
This is fixed by http://patchwork.ozlabs.org/patch/142548/ (which hasn't been applied yet but hopefully will be soon).
2012/2/24 Peter Maydell <email address hidden>:
> This is fixed by http://patchwork.ozlabs.org/patch/142548/ (which hasn't
> been applied yet but hopefully will be soon).
>
It looks like a workaround to me as if you feed NULL to
qemu_opt_find() it will still crashing.
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/939995
>
> Title:
> v1.0-1172-g235fe3b crashes (opts=0x0)
>
> Status in QEMU:
> New
>
> Bug description:
> C:\msys\home\User\qemu\i386-softmmu>gdb --args qemu-system-i386.exe -L ..\pc-bios
> GNU gdb (GDB) 7.3
> Copyright (C) 2011 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law. Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "mingw32".
> For bug reporting instructions, please see:
> <http://www.gnu.org/software/gdb/bugs/>...
> Reading symbols from C:\msys\home\User\qemu\i386-softmmu/qemu-system-i386.exe...
> done.
> (gdb) r
> Starting program: C:\msys\home\User\qemu\i386-softmmu/qemu-system-i386.exe -L ..\\pc-bios
> [New Thread 4724.0x1224]
>
> Program received signal SIGSEGV, Segmentation fault.
> 0x004eeda6 in qemu_opt_get (opts=0x0, name=0x68a7c3 "kernel")
> at qemu-option.c:545
> 545 QemuOpt *opt = qemu_opt_find(opts, name);
> (gdb) bt
> #0 0x004eeda6 in qemu_opt_get (opts=0x0, name=0x68a7c3 "kernel")
> at qemu-option.c:545
> #1 0x004c7166 in qemu_main (argc=3, argv=0x3e5200, envp=0x0)
> at C:/msys/home/User/qemu/vl.c:3250
> #2 0x004c906a in SDL_main (argc=3, argv=0x3e5200)
> at C:/msys/home/User/qemu/vl.c:102
> #3 0x0061dcf4 in console_main ()
> #4 0x0061ddb4 in WinMain@16 ()
> #5 0x006329fb in main ()
> (gdb)
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/qemu/+bug/939995/+subscriptions
Peter's fix had been included here:
http://git.qemu.org/?p=qemu.git;a=commitdiff;h=967c0da73a7b0da186baba6
... so I think we can close this bug ticket now.
|