From 007d2bcbb1bfac12f2737f05837fc1a5ce68151a Mon Sep 17 00:00:00 2001 From: "(no author)" <(no author)@54d463be-8e91-2dee-dedb-b68131a5f0ec> Date: Thu, 4 Nov 2004 23:59:44 +0000 Subject: git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/athena@5 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/char/char.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/char/char.c b/src/char/char.c index e6cf4393e..92880b84d 100644 --- a/src/char/char.c +++ b/src/char/char.c @@ -1596,7 +1596,9 @@ int parse_tologin(int fd) { // only login-server can have an access to here. // so, if it isn't the login-server, we disconnect the session (fd != login_fd). - if (fd != login_fd || session[fd]->eof) { + if (fd != login_fd) + session[fd]->eof = 1; + if(session[fd]->eof) { if (fd == login_fd) { printf("Char-server can't connect to login-server (connection #%d).\n", fd); login_fd = -1; @@ -2486,7 +2488,9 @@ int parse_char(int fd) { struct char_session_data *sd; unsigned char *p = (unsigned char *) &session[fd]->client_addr.sin_addr; - if (login_fd < 0 || session[fd]->eof) { // disconnect any player (already connected to char-server or coming back from map-server) if login-server is diconnected. + if (login_fd < 0) + session[fd]->eof = 1; + if(session[fd]->eof) { // disconnect any player (already connected to char-server or coming back from map-server) if login-server is diconnected. if (fd == login_fd) login_fd = -1; close(fd); -- cgit v1.2.3-70-g09d2