From 0698f0b34299624e6ac535442b4e7b8894dd8167 Mon Sep 17 00:00:00 2001 From: FlavioJS Date: Sat, 2 Dec 2006 04:21:35 +0000 Subject: - Replaced @send with the version I use for testing packets. Can display the packet length. Supports dynamic packets, quoted strings with escaped characters and fixed/variable length, and normal/hex byte/word/long data types. The number of fields is not limited, but it automatically stops parsing when the packet is full. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9387 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/common/socket.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/common/socket.h') diff --git a/src/common/socket.h b/src/common/socket.h index eb3a78f7e..9552575f3 100644 --- a/src/common/socket.h +++ b/src/common/socket.h @@ -72,6 +72,10 @@ extern time_t stall_time; #define WBUFW(p,pos) (*(unsigned short*)((p) + (pos))) #define WBUFL(p,pos) (*(unsigned long*)((p) + (pos))) +#define TOB(n) ((unsigned char)(n)) +#define TOW(n) ((unsigned short)(n)) +#define TOL(n) ((unsigned long)(n)) + //FD_SETSIZE must be modified on the project files/Makefile, since a change here won't affect // dependant windows libraries. /* -- cgit v1.2.3-60-g2f50