fix auth flag in tunnel and redir

This commit is contained in:
Max Lv
2015-09-03 12:30:06 +08:00
parent 9d2c14b335
commit 656c97e64e
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -378,9 +378,9 @@ static void remote_send_cb(EV_P_ ev_io *w, int revents)
}
if (auth) {
ss_addr_to_send[0] |= ONETIMEAUTH_FLAG;
ss_onetimeauth(ss_addr_to_send + addr_len, ss_addr_to_send, addr_len);
addr_len += ONETIMEAUTH_BYTES;
ss_addr_to_send[0] |= ONETIMEAUTH_FLAG;
}
int s = send(remote->fd, ss_addr_to_send, addr_len, 0);
+1 -1
View File
@@ -420,9 +420,9 @@ static void remote_send_cb(EV_P_ ev_io *w, int revents)
}
if (auth) {
ss_addr_to_send[0] |= ONETIMEAUTH_FLAG;
ss_onetimeauth(ss_addr_to_send + addr_len, ss_addr_to_send, addr_len);
addr_len += ONETIMEAUTH_BYTES;
ss_addr_to_send[0] |= ONETIMEAUTH_FLAG;
}
int s = send(remote->fd, ss_addr_to_send, addr_len, 0);