sockcli.pp 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. Program Client;
  2. {
  3. $Id$
  4. This file is part of the Free Component Library (FCL)
  5. Copyright (c) 1999-2000 by the Free Pascal development team
  6. See the file COPYING.FPC, included in this distribution,
  7. for details about the copyright.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  11. **********************************************************************}
  12. {
  13. TUnixSocket client program. Before running this, run either
  14. 'socksvr', or 'dsocksvr' in another terminal
  15. or in the background.
  16. }
  17. uses ssockets;
  18. var
  19. S : String;
  20. i : longint;
  21. begin
  22. S:='This is a textstring sent by the client'#10;
  23. With TUnixSocket.Create('ServerSoc') do
  24. begin
  25. For I:=1 to 10 do
  26. Write(S[1],Length(S));
  27. S:='QUIT'#10;
  28. Write(S[1],Length(S));
  29. Free;
  30. end;
  31. end.
  32. {
  33. $Log$
  34. Revision 1.2 2000-07-13 11:33:04 michael
  35. + removed logs
  36. }