About to go (more) insane. SegFault calling GetOwnPropertyNames().

33 views
Skip to first unread message

Scott Duensing

unread,
Feb 1, 2016, 7:53:13 PM2/1/16
to v8-users
The exact line is:  http://skunkworks.kangaroopunch.com/projects/scripting/repository/revisions/master/entry/Scripting/scripting.cpp#L76

What this bit of (unfinished) code does is allow you to load scripts into individual contexts and call between them passing JSON in and out to exchange data.  

This was working.  Then I added the code to pass JSON objects in as function arguments.  Now nothing works.  There's something wrong, scope-wise, but I can't find it.  I'm new to V8 and finding docs is uphill work.  :-(   Can someone take pity on my poor brain and lend a hand?  The platform is x64 Ubuntu 15.10.  The script I used to download and build V8 is included.

Thank you in advance!


Scott

Scott Duensing

unread,
Feb 2, 2016, 8:40:04 PM2/2/16
to v8-users
I gave up.  After fixing a few Local<Object> returns that weren't Escape()'ed I ended up with the code blowing up for not having a HandleScope...  Which made no sense because where it blew up was on the line where I had created an EscapableHandleScope.

I worked around the entire mess of trying to pass Local<Object>s around by converting them to JSON strings and returning those.  Meh.


Scott

Jochen Eisinger

unread,
Feb 3, 2016, 4:07:37 AM2/3/16
to v8-users
I skimmed through the source you've linked, but it's not entirely clear to me what you're actually doing. If you could post the non-working version and the crash stack that might help.

Assuming you managed to get stuff working with strings, and are happy with this solution, I guess that's fine, right?

--
--
v8-users mailing list
v8-u...@googlegroups.com
http://groups.google.com/group/v8-users
---
You received this message because you are subscribed to the Google Groups "v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to v8-users+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Scott Duensing

unread,
Feb 3, 2016, 1:20:44 PM2/3/16
to v8-u...@googlegroups.com
I'm happy enough for the time being.  There's overhead doing it my way that I'd like to remove, but I can come back to it when I'm less mad at this particular bug.  :-)

Thanks for taking a look.

You received this message because you are subscribed to a topic in the Google Groups "v8-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/v8-users/qIl7Y4ESeis/unsubscribe.
To unsubscribe from this group and all its topics, send an email to v8-users+u...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages