Hoi all, Just stared to use clipsal in my house and im making a video/audio page inside piced. I made a server app on my computer to handel all the requests from my toutchscreen. All wordk great but after a while piced gives an out of memory error. It seems to happen every time i use the 'ReadClientSocket' function. Is this a bug or am i doing something wrong? The code im justing works like this: [COLOR="Blue"] if not ClientSocketConnected then OpenClientSocket('127.0.0.1', 23); if ClientSocketConnected then begin writeln('client connected'); repeat ReadClientSocket(s, #13#10); if s <> '' then begin writeln(s); WriteClientSocket(s); WriteClientSocket(#13#10); end; until s = ''; end;[/COLOR] I also tried to do the same thing while making the server a host and the error doesnt accour: [COLOR="blue"]if not ServerSocketActive then OpenServerSocket(23); if ServerSocketActive then begin writeln('im a server'); if ServerSocketHasClient then begin writeln('i have a client'); repeat ReadServerSocket(s, #13#10); if s <> '' then begin writeln(s); WriteServerSocket(s); WriteServerSocket(#13#10); end; until s = ''; end; end;[/COLOR] Am i missing some kind of cleanup function for the 'ReadClientSocket' function?