From 37ff21f64e4874443dffceac83ed3f3ba15b4127 Mon Sep 17 00:00:00 2001 From: beware Date: Mon, 19 Jan 2009 22:21:55 +0000 Subject: [PATCH] fixed bug of udp not working when using listen git-svn-id: file:///svnroot/lcore/trunk@24 b1de8a11-f9be-4011-bde0-cc7ace90066a --- lsocket.pas | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lsocket.pas b/lsocket.pas index a9adbd3..cfa1bd1 100755 --- a/lsocket.pas +++ b/lsocket.pas @@ -333,7 +333,10 @@ var begin if state <> wsclosed then close; udp := uppercase(proto) = 'UDP'; - if udp then socktype := SOCK_DGRAM else socktype := SOCK_STREAM; + if udp then begin + socktype := SOCK_DGRAM; + dgram := true; + end else socktype := SOCK_STREAM; origaddr := addr; if addr = '' then begin -- 2.30.2