diff options
| author | Russ White <russ@riw.us> | 2017-05-10 13:51:47 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-05-10 13:51:47 -0400 |
| commit | 00a1578051ceeb26b0b9c2c3344cac1f202e047d (patch) | |
| tree | 248b55b1ab56e39025d9902c53564286558eda60 /lib/smux.c | |
| parent | 0896b755080b300116d493444bfc05e2ef7ca9f6 (diff) | |
| parent | c94671b82f790492ceee226f98a65ad7e7e09967 (diff) | |
Merge pull request #408 from qlyoung/remove-thread-macros
*: remove THREAD_ON macros, add nullity check
Diffstat (limited to 'lib/smux.c')
| -rw-r--r-- | lib/smux.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/smux.c b/lib/smux.c index 370b8f138e..6e53061d45 100644 --- a/lib/smux.c +++ b/lib/smux.c @@ -1197,13 +1197,18 @@ smux_event (enum smux_event event, int sock) switch (event) { case SMUX_SCHEDULE: - smux_connect_thread = thread_add_event (smux_master, smux_connect, NULL, 0); + smux_connect_thread = NULL; + thread_add_event(smux_master, smux_connect, NULL, 0, + &smux_connect_thread); break; case SMUX_CONNECT: - smux_connect_thread = thread_add_timer (smux_master, smux_connect, NULL, 10); + smux_connect_thread = NULL; + thread_add_timer(smux_master, smux_connect, NULL, 10, + &smux_connect_thread); break; case SMUX_READ: - smux_read_thread = thread_add_read (smux_master, smux_read, NULL, sock); + smux_read_thread = NULL; + thread_add_read(smux_master, smux_read, NULL, sock, &smux_read_thread); break; default: break; |
