[noPoll] nopoll_conn_get_msg is blocking unlike what documentation says

Morel Bérenger berenger.morel at sga-automation.com
Thu Dec 21 14:59:46 CET 2017


Hello.

When trying to make nopoll work with my own polling mechanism, I have
noticed that nopoll_conn_get_msg is blocking.
Here is the stack trace when breaking in with gdb:

====================
Program received signal SIGINT, Interrupt.
0x00007ffff70e247d in __libc_recv (fd=10, buf=0x7fffffffcf30, n=2,
flags=-1) at ../sysdeps/unix/sysv/linux/x86_64/recv.c:29
29      ../sysdeps/unix/sysv/linux/x86_64/recv.c: Aucun fichier ou
dossier de ce type.
(gdb) bt
#0  0x00007ffff70e247d in __libc_recv (fd=10, buf=0x7fffffffcf30, n=2,
flags=-1) at ../sysdeps/unix/sysv/linux/x86_64/recv.c:29
#1  0x00007ffff7bcbaeb in nopoll_conn_default_receive (conn=<optimized
out>, buffer=0x7fffffffcf30 "\207\254A", buffer_size=<optimized out>) at
 nopoll_conn.c:2158
#2  0x00007ffff7bcda14 in __nopoll_conn_receive (conn=0x6201b0,
buffer=0x7fffffffcf30 "\207\254A", maxlen=2) at nopoll_conn.c:2349
#3  0x00007ffff7bcf6e6 in nopoll_conn_get_msg (conn=0x6201b0) at
nopoll_conn.c:3231
====================

Maybe it is caused by the fact I used "nopoll_conn_new_with_socket( ctx,
NULL, socket_fd, ip, port, hostname, url, protocols, NULL);", ctx only
behing the result of the nopoll_ctx_new() function?

-- 
SGA Automation
27 Rue Jean-Philippe Rameau
Pôle Delta
76000 Rouen
Tel : 02 32 10 38 53
Fax : 02 32 10 11 30
www.sga-automation.com
Email : berenger.morel at sga-automation.com




More information about the noPoll mailing list