Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

segfault with v3.1.0 and possibly --harmony-arrow-functions #2561

Labels
c++ Issues and PRs that require attention from people who are familiar with C++.

Comments

@freak4pc
Copy link

When trying to run the following
iojs --harmony-arrow-functions dreamdate.js

This issue isn't happening in io.js v2.5.0 , and also doesn't happen on io.js v3.0.
Starts from v3.1.0.

screen shot 2015-08-26 at 4 49 53 pm

@mscdex
Copy link
Contributor

mscdex commented Aug 26, 2015

Can you produce a minimal, reproducible example? What platform is this on?

I just tried a simple script (with --harmony-arrow-functions) that used fat arrows on v3.1.0 on Linux and did not encounter this issue.

@freak4pc
Copy link
Author

It seems to work fine here as well with a smaller sample,
So I guess it's not directly related to --harmony-arrow-functions

The following script works fine on 3.2.0 :

'use strict'

let callback = (name) => {
        console.log("hello " + name)
}

callback("shai")

But specifically when running my server (which works fine on 2.5.0 as well as 3.0.0) , it crashes with a Segfault.

Is there any way to get more verbose output so I can give a better direction for this?

Thank you

@silverwind
Copy link
Contributor

What OS is that? Try running it through either gdb or lldb, for example lldb -- iojs file.js and then r and probably bt.

@silverwind silverwind added the c++ Issues and PRs that require attention from people who are familiar with C++. label Aug 26, 2015
@ChALkeR
Copy link
Member

ChALkeR commented Aug 26, 2015

See #1655 just in case.

@yoshuawuyts
Copy link

Not sure if related, but found an issue where 0.12.x gives an ECONNREFUSED error, 3.2.0 segfaults. Can create a separate issue if not related.

img
screen shot 2015-08-31 at 12 40 41

txt

~/src/dlivr/api master
❯ npm start

> [email protected] start /Users/yw/src/dlivr/api
> node .

zsh: segmentation fault  npm start

~/src/dlivr/api master
❯ node -v
v3.2.0

~/src/dlivr/api master
❯ nvm use 0.12
^[kkNow using node v0.12.7 (npm v2.11.3)

~/src/dlivr/api master
❯ npm start

> [email protected] start /Users/yw/src/dlivr/api
> node .

{"name":"log","type":"static","message":"debug"}
{"name":"port","message":1337,"type":"static"}
{"name":"env","message":"development","type":"static"}
Knex:Error Pool2 - Error: connect ECONNREFUSED
Knex:Error Pool2 - Error: connect ECONNREFUSED
^C

~/src/dlivr/api master  2m 20s
❯ nvm use 3
Now using io.js v3.2.0 (npm v2.13.3)

@Fishrock123
Copy link
Contributor

@yoshuawuyts can you open a new issue?

Also, can both of you use either lldb or gdb, or mdb to get a thorough breakdown of what is happening in the segfault? Feel free to ask if you need more info, setting this stuff up isn't particularly trivial.

@Fishrock123 Fishrock123 changed the title Super odd Issue - 23267 segmentation fault segfault with v3.1.0 and possibly --harmony-arrow-functions Aug 31, 2015
@yoshuawuyts
Copy link

@Fishrock123 I'm willing to run that, but could you point me in the right direction on how to set that up? Thanks!

@Fishrock123
Copy link
Contributor

Been a while since I did it. @thlorenz has a guide here for lldb on OS X: https://gist.github.com/thlorenz/30bf0a3f67b1d97b2945 (Not sure if it is up-to-date, when I did it I didn't patch lldb and it worked?)

@Fishrock123
Copy link
Contributor

@freak4pc Could you let us know what OS you're seeing this on at least? :)

@freak4pc
Copy link
Author

freak4pc commented Sep 1, 2015

Sorry guys, I'm pretty much flooded with work now.
I'll try to get more info from lldb tomorrow and post it here...

@evanlucas
Copy link
Contributor

is this still an issue in the latest stable (v4.2.1 as of now)?

@evanlucas
Copy link
Contributor

Closing due to inactivity and the fact that arrow functions are no longer behind a flag as of v4. If this is still an issue please feel to reopen. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment