Closed
Bug 272336
Opened 20 years ago
Closed 20 years ago
array_sort uses GC-unsafe temporary memory to hold jsvals
Categories
(Core :: JavaScript Engine, defect, P1)
Tracking
()
RESOLVED
FIXED
mozilla1.8alpha6
People
(Reporter: timeless, Assigned: brendan)
Details
(4 keywords)
Attachments
(1 file)
|
1.87 KB,
patch
|
shaver
:
review+
jay
:
approval-aviary1.0.5+
jay
:
approval1.7.9+
|
Details | Diff | Splinter Review |
01010113()
js3250.dll!js_Interpret(JSContext * cx=0x02a38600, long *
result=0x0012ce38) Line 2800 + 0x213 C
js3250.dll!js_Invoke(JSContext * cx=0x00acb7d2, unsigned int
argc=44271104, unsigned int flags=1232440) Line 958 + 0xa C
js3250.dll!js_InternalInvoke(JSContext * cx=0x06e8c0e4, JSObject *
obj=0x027fc860, long fval=41928824, unsigned int flags=0, unsigned int argc=2,
long * argv=0x0012cef0, long * rval=0x0012cf08) Line 1035 + 0xe C
js3250.dll!sort_compare(const void * a=0x072b0c30, const void *
b=0x072b0c34, void * arg=0x0012cf9c) Line 769 + 0x55 C
js3250.dll!HeapSortHelper(int building=1, HSortArgs * hsa=0x05b4fd98,
unsigned int lo=109, unsigned int hi=313) Line 691 + 0x20 C
js3250.dll!js_HeapSort(void * vec=0x072b08d0, unsigned int nel=313,
unsigned int elsize=4, int (const void *, const void *, void *)*
cmp=0x00ab6074, void * arg=0x0012cf9c) Line 725 + 0xc C
> js3250.dll!array_sort(JSContext * cx=0x02a38600, JSObject *
obj=0x027fbca0, unsigned int argc=313, long * argv=0x06e8c0dc, long *
rval=0x0012d010) Line 889 + 0x30 C
js3250.dll!js_Invoke(JSContext * cx=0x00acb7d2, unsigned int
argc=44271104, unsigned int flags=1232440) Line 941 + 0x11 CFlags: blocking1.8a6?
Flags: blocking1.7.6?
Flags: blocking1.7.5?
| Assignee | ||
Comment 1•20 years ago
|
||
What, no IRC log? Here's the relevant part: * spidercrasher reads js.exe output for dis(scr_compare) <brendan> so can you verify that fp->argv[1] is the same value as obj at the crash site ? <spidercrasher> (void*)fp->argv[1] == obj 1 int <brendan> ok, so how could it be GC'd? <brendan> it must have been GC'd before fp was set up <brendan> yikes <brendan> is array_sort really using unrooted jsval *vec storage? * spidercrasher looks up <brendan> file a bug, array_sort uses GC-unsafe temporary memory to hold jsvals <brendan> nominate for branches <spidercrasher> sure looks like it <brendan> thanks <brendan> see, stacks are helpful ;-) /be
| Assignee | ||
Comment 2•20 years ago
|
||
This is painless, good for all active branches. /be
| Assignee | ||
Updated•20 years ago
|
Attachment #167389 -
Flags: review?(shaver)
Comment 3•20 years ago
|
||
Comment on attachment 167389 [details] [diff] [review] proposed fix Slick! r=shaver.
Attachment #167389 -
Flags: review?(shaver) → review+
| Assignee | ||
Comment 4•20 years ago
|
||
Checked in. I'll request branch approval on the patch next. /be
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Flags: blocking1.8a6?
Resolution: --- → FIXED
| Assignee | ||
Comment 5•20 years ago
|
||
Comment on attachment 167389 [details] [diff] [review] proposed fix Rare crash fix, no change to web compat w.r.t. Firefox 1.0, so good for 1.7.5. /be
Attachment #167389 -
Flags: approval1.7.5?
Comment 6•20 years ago
|
||
Comment on attachment 167389 [details] [diff] [review] proposed fix a=asa for 1.7.5 checkin
Attachment #167389 -
Flags: approval1.7.5? → approval1.7.5+
Comment 8•20 years ago
|
||
Approving, get it in for 1.7.6 quickly. (why not 1.0.1 as well?)
Flags: blocking1.7.6? → blocking1.7.6+
Comment 9•20 years ago
|
||
Comment on attachment 167389 [details] [diff] [review] proposed fix This hasn't gone into any of the branches it seems, but its too late now. Unsetting approval.
Attachment #167389 -
Flags: approval1.7.5+
Updated•20 years ago
|
Flags: blocking1.7.6+ → blocking1.7.6-
Comment 10•19 years ago
|
||
Comment on attachment 167389 [details] [diff] [review] proposed fix Why not checked into branch yet? Isn't it considered as a vulnerability?
Attachment #167389 -
Flags: approval1.7.9?
Attachment #167389 -
Flags: approval-aviary1.0.5?
Updated•19 years ago
|
Flags: blocking1.7.9?
Flags: blocking-aviary1.0.5?
| Reporter | ||
Comment 11•19 years ago
|
||
it's just a crash, you're never going to be able to convince it to go somewhere useful based on how the gc behaves. that said it really should go into the branch, it just got lost and now needs new approvals.
Comment 12•19 years ago
|
||
Comment on attachment 167389 [details] [diff] [review] proposed fix Let's get this landed on the branches. a=jay
Attachment #167389 -
Flags: approval1.7.9?
Attachment #167389 -
Flags: approval1.7.9+
Attachment #167389 -
Flags: approval-aviary1.0.5?
Attachment #167389 -
Flags: approval-aviary1.0.5+
Updated•19 years ago
|
Flags: blocking1.7.9?
Flags: blocking1.7.9+
Flags: blocking-aviary1.0.5?
Flags: blocking-aviary1.0.5+
| Assignee | ||
Comment 13•19 years ago
|
||
Fixed on the branches. /be
Keywords: fixed-aviary1.0.5,
fixed1.7.9
Updated•19 years ago
|
Flags: testcase-
You need to log in
before you can comment on or make changes to this bug.
Description
•