From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from qmta02.westchester.pa.mail.comcast.net (qmta02.westchester.pa.mail.comcast.net [IPv6:2001:558:fe14:43:76:96:62:24]) by hurricane.the-brannons.com (Postfix) with ESMTP id D2FFE78481 for ; Tue, 11 Feb 2014 03:56:03 -0800 (PST) Received: from omta22.westchester.pa.mail.comcast.net ([76.96.62.73]) by qmta02.westchester.pa.mail.comcast.net with comcast id QzuZ1n0031ap0As51zvPCT; Tue, 11 Feb 2014 11:55:23 +0000 Received: from eklhad ([107.5.36.150]) by omta22.westchester.pa.mail.comcast.net with comcast id QzvP1n00A3EMmQj3izvPxB; Tue, 11 Feb 2014 11:55:23 +0000 To: Edbrowse-dev@lists.the-brannons.com From: Karl Dahlke User-Agent: edbrowse/3.5.1 Date: Tue, 11 Feb 2014 06:55:22 -0500 Message-ID: <20140111065522.eklhad@comcast.net> Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20121106; t=1392119723; bh=hI9VMrKfoaXZ5y6F0NpLGLhCivp3VWsR3RnYih4uQmk=; h=Received:Received:To:From:Reply-to:Subject:Date:Message-ID: Mime-Version:Content-Type; b=OsY2IfngHRh1/gAxK9K5t5wc4LhZlsY1vm97utsaSUY60VGvPdibeT+H6FYG7EqpA S2OHS5pPxf1ETiOX8TLCNsmZ3nLZXWRR/ub7iAe2nbVOcy3HORl2n3e0D4xxCOlb4J WqrIzhXyjIUZmJT/zBjLaQzQIZUs/ZxRzxg8BmpRESKMkBVixrUOCZacaRNbcLHnEI iBkuVDQW7eDTyH8H6ftNSkjHSNBM6aqfXlISn8bXWmCo4RgUQ/3rEWdG5v2FrJ1Zzq Vv40vejoUryAp6rMp7pkwR97LjctaO1kfvmHnDrYbJfKI0Q5o2LwcsiW+BbiynK0cb vW8YCy2ygRD2g== Subject: [Edbrowse-dev] AutoCompartment other window X-BeenThere: edbrowse-dev@lists.the-brannons.com X-Mailman-Version: 2.1.17 Precedence: list Reply-To: Karl Dahlke List-Id: Edbrowse Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Feb 2014 11:56:04 -0000 Well, it only took a couple hours after my cleanup push to run into a reproducible segfault. I tracked it down to an AutoCompartment call. Remember I said they were all gone; there is one that we actually need in html.cpp, just before we destroy the object associated with the tag. It's part of freeWindow(). Naturally I used the same old line, but that sets the compartment of the current window; we are not always freeing the current window. q5 will quit session 5, for example. So this is the only AutoCompartment that is not based on cw. I fixed this and the segfault went away. A question for you in jsdom.cpp function domLink(). This line JS::RootedObject owner_root(cw->jss->jcx, owner); Then you use owner_root instead of owner thereafter. Is this necessary? owner is safely rooted on the heap and isn't going to go anywhere. We could just use owner throughout and it would be much clearer. Karl Dahlke