Parcourir la source

updates

git-svn-id: https://svn.code.sf.net/p/rathena/svn/branches/stable@452 54d463be-8e91-2dee-dedb-b68131a5f0ec
amber il y a 20 ans
Parent
commit
a581a1eb26
2 fichiers modifiés avec 3 ajouts et 1 suppressions
  1. 2 0
      Changelog.txt
  2. 1 1
      src/map/clif.c

+ 2 - 0
Changelog.txt

@@ -1,5 +1,7 @@
 Date	Added
 12/4
+	* Fixed a crash in clif_send when player disconnects but player
+	  object is not fully removed from map [MouseJstr]
 	* Fixed a crash associated with NPC_BARRIER [MouseJstr]
 	* Renamed flush_fifos_at_exit to flush_fifos [MouseJstr]
 	* call check_connect_char_server() on char_server disconnect [MouseJstr]

+ 1 - 1
src/map/clif.c

@@ -256,7 +256,7 @@ int clif_send_sub(struct block_list *bl, va_list ap)
 		break;
 	}
 
-	if (sd) {
+	if ((sd != NULL) && (session[sd->fd] != NULL)) {
 		if (WFIFOP(sd->fd,0) == buf) {
 			printf("WARNING: Invalid use of clif_send function\n");
 			printf("         Packet x%4x use a WFIFO of a player instead of to use a buffer.\n", WBUFW(buf,0));