Procházet zdrojové kódy

tun2socks: fix possible crash due to the use of a wrong dead-variable

ambrop7 před 13 roky
rodič
revize
d551b48e32
1 změnil soubory, kde provedl 3 přidání a 3 odebrání
  1. 3 3
      tun2socks/tun2socks.c

+ 3 - 3
tun2socks/tun2socks.c

@@ -1564,10 +1564,10 @@ err_t client_sent_func (void *arg, struct tcp_pcb *tpcb, u16_t len)
             SYNC_DECL
             SYNC_FROMHERE
             client_socks_recv_initiate(client);
-            DEAD_ENTER(client->dead)
+            DEAD_ENTER(client->dead_client)
             SYNC_COMMIT
-            DEAD_LEAVE2(client->dead)
-            if (DEAD_KILLED) {
+            DEAD_LEAVE2(client->dead_client)
+            if (DEAD_KILLED == -1) {
                 return ERR_ABRT;
             }
         }