NEAT-project / neat

A New, Evolutive API and Transport-Layer Architecture for the Internet
https://www.neat-project.org/
BSD 3-Clause "New" or "Revised" License
66 stars 19 forks source link

nsa_pipe() causes "Segmentation fault (core dumped)" #380

Closed robustness closed 7 years ago

robustness commented 7 years ago

Please just copy and paste the following lines of code and save as hello.c. Then compile and run the code: $ gcc -Wall -lneat-socketapi-static hello.c -o hello $ ./hello

include

include

include

include

int main() { int fd[2]; int ret; ret = nsa_pipe(fd); if (ret == 0) { printf("Sucessfully nsa_pipe\n"); } else { printf("nsa_pipe failed!\n"); } return 0; }

dreibh commented 7 years ago

Could you try the "neat-socketapi" branch? It should fix this issue.

(Note: you just need to include neat-socketapi.h. neat.h and neat_queue.h are not needed for the sockets API.)

dreibh commented 7 years ago

Pull request #383 fixes the issue.