summaryrefslogtreecommitdiff
path: root/src/char
diff options
context:
space:
mode:
author(no author) <(no author)@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-11-04 23:59:44 +0000
committer(no author) <(no author)@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-11-04 23:59:44 +0000
commit007d2bcbb1bfac12f2737f05837fc1a5ce68151a (patch)
tree006942a149bb8e40d6daf84528e289a3ee7264c9 /src/char
parent195dffc20af1fb32c7e4119988911b72955aeabc (diff)
downloadhercules-007d2bcbb1bfac12f2737f05837fc1a5ce68151a.tar.gz
hercules-007d2bcbb1bfac12f2737f05837fc1a5ce68151a.tar.bz2
hercules-007d2bcbb1bfac12f2737f05837fc1a5ce68151a.tar.xz
hercules-007d2bcbb1bfac12f2737f05837fc1a5ce68151a.zip
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/athena@5 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/char')
-rw-r--r--src/char/char.c8
1 files 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);