Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
Networking and Web Programming
»
lnet - TCP server-client problem under linux
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
Forum Rules
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
Recent
Conscious Artificial Inte...
by
schuler
[
Today
at 02:42:53 am]
Implementing an Elo ratin...
by
mas steindorff
[
Today
at 02:22:34 am]
[New Component] ExtTabCtr...
by
jianwt
[
Today
at 02:21:39 am]
You can embed Windows Con...
by
Aruna
[
Today
at 01:42:47 am]
Can /my/ AI help me with ...
by
microxa
[
Today
at 12:56:29 am]
IndySecOpenSSL is now ava...
by
TheMouseAUS
[
Today
at 12:08:51 am]
RunFormula: math expressi...
by
stormray
[June 17, 2026, 10:32:05 pm]
Codepage issue in console...
by
ASerge
[June 17, 2026, 09:36:27 pm]
Pdf Viewer in Pascal
by
Tomxe
[June 17, 2026, 07:18:20 pm]
Canvas size
by
Thaddy
[June 17, 2026, 07:15:50 pm]
[Reopened] TSaveDialog
by
Thaddy
[June 17, 2026, 05:12:17 pm]
What am I missing here? [...
by
Thaddy
[June 17, 2026, 03:39:02 pm]
Questions about 16 color ...
by
wp
[June 17, 2026, 01:45:07 pm]
TCHATGPT — An Artificial ...
by
Weiss
[June 17, 2026, 07:00:13 am]
FPC Unleashed (inline var...
by
440bx
[June 16, 2026, 11:53:51 pm]
RFC: Separation of MCU an...
by
ackarwow
[June 16, 2026, 11:06:14 pm]
Error with last fixes_3.2...
by
patyit
[June 16, 2026, 09:49:02 pm]
Mundo Medieval 3D MMORPG ...
by
Rodrigo Robles
[June 16, 2026, 06:06:17 pm]
Which Control should I us...
by
wp
[June 16, 2026, 05:08:55 pm]
Just Question App paramet...
by
eldonfsr
[June 16, 2026, 04:50:19 pm]
Content is distorting / w...
by
Handoko
[June 16, 2026, 03:53:02 pm]
ZxTune chiptunes player
by
Guva
[June 16, 2026, 12:41:14 pm]
Onscroll event for Tscrol...
by
laz_one_or2
[June 16, 2026, 11:16:39 am]
Fpcupdeluxe
by
CharlyTango
[June 16, 2026, 10:35:33 am]
Compiling Qt6 project on ...
by
wp
[June 16, 2026, 10:14:53 am]
« previous
next »
Print
Pages: [
1
]
Author
Topic: lnet - TCP server-client problem under linux (Read 6831 times)
dfeher
New Member
Posts: 19
lnet - TCP server-client problem under linux
«
on:
August 28, 2010, 09:50:16 am »
Hello!
I've ran into a problem using lNet TCP connection. I have a server and a client connected via TCP protocol. Under ubuntu 10.04 i386 the server senses when the client connects through OnConnect action but when the client disconnects nothing happens although the OnDisconnect event is also used... I've tried the same programs under windows XP and there were no such problems; the server sensed when the client disconnected and vice versa. Everything is written according to the example programs...
I don't know if it's a linux or ubuntu specialty or an lNet bug.
Logged
JohnvdWaeter
Full Member
Posts: 185
Re: lnet - TCP server-client problem under linux
«
Reply #1 on:
August 28, 2010, 11:03:56 am »
Hi,
AFAIK you MUST have an OnReceive-event and you MUST read data here, although there may be nothing to read. Only then other events are fired. Again: AFAIK.
John
Logged
Almindor
Sr. Member
Posts: 412
Re: lnet - TCP server-client problem under linux
«
Reply #2 on:
August 28, 2010, 11:49:56 am »
Exactly as John says, you MUST have OnReceive and do a .Get or .GetMessage inside when called. This is because lNet has NO internal buffers and disconnects (from the other side) are reported by the kernel via recv() calls which give 0 result.
Logged
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
Networking and Web Programming
»
lnet - TCP server-client problem under linux
TinyPortal
© 2005-2018