summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFlavioJS <FlavioJS@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-10-03 22:23:31 +0000
committerFlavioJS <FlavioJS@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-10-03 22:23:31 +0000
commitd4db7786bb9270c7007ba3e427a6f8bc99ff7551 (patch)
treecc75bf0dbc449c6e293ec07c86355e4880393d5e /src
parent7d4c817f696f68310adf7f13647355adb8ef12b3 (diff)
downloadhercules-d4db7786bb9270c7007ba3e427a6f8bc99ff7551.tar.gz
hercules-d4db7786bb9270c7007ba3e427a6f8bc99ff7551.tar.bz2
hercules-d4db7786bb9270c7007ba3e427a6f8bc99ff7551.tar.xz
hercules-d4db7786bb9270c7007ba3e427a6f8bc99ff7551.zip
* Delete ST_LOGIN auth in chrif_disconnectplayer (followup to r13256, bugreport:2292)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13257 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r--src/map/chrif.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/map/chrif.c b/src/map/chrif.c
index 7ff0c12e6..0f5221994 100644
--- a/src/map/chrif.c
+++ b/src/map/chrif.c
@@ -1016,10 +1016,16 @@ int chrif_accountban(int fd)
int chrif_disconnectplayer(int fd)
{
struct map_session_data* sd;
+ int account_id = RFIFOL(fd, 2);
- sd = map_id2sd(RFIFOL(fd, 2));
- if(sd == NULL)
+ sd = map_id2sd(account_id);
+ if( sd == NULL )
+ {
+ struct auth_node* auth = chrif_search(account_id);
+ if( auth != NULL && chrif_auth_delete(account_id, auth->char_id, ST_LOGIN) )
+ return 0;
return -1;
+ }
if (!sd->fd)
{ //No connection