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

gnu99 vs c99 #41

Open
rainwoodman opened this issue Oct 11, 2018 · 0 comments
Open

gnu99 vs c99 #41

rainwoodman opened this issue Oct 11, 2018 · 0 comments

Comments

@rainwoodman
Copy link
Collaborator

On Cori, when compiling with anaconda's cross compiling toolchain, if we use -c99, strdup will cause a segfault.

The reason is likely because strdup is not part of c99, and thus the compilation will not see a prototype to the function, causing the compiler to truncate the return value of the function to 'int' which is shorter than a true pointer on x64.

We shall update Makefile.travis; as it serves as an example for compiling in such situation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant