settimeo.inc 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. {
  2. This file is part of the Free Pascal run time library.
  3. Copyright (c) 2004 by Michael Van Canneyt,
  4. member of the Free Pascal development team.
  5. See the file COPYING.FPC, included in this distribution,
  6. for details about the copyright.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY;without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  10. **********************************************************************}
  11. {$ifdef usestime}
  12. function stime (t:ptime_t):cint;
  13. begin
  14. stime:=do_SysCall(Syscall_nr_stime,TSysParam(t));
  15. end;
  16. function fpsettimeofday(tp:ptimeval;tzp:ptimezone):cint;
  17. begin
  18. fpsettimeofday:=stime(@tp^.tv_sec);
  19. end;
  20. {$else}
  21. function fpsettimeofday(tp:ptimeval;tzp:ptimezone):cint;
  22. begin
  23. fpsettimeofday:=do_SysCall(Syscall_nr_settimeofday,TSysParam(@tp),TSysParam(tzp));
  24. end;
  25. {$endif}
  26. {
  27. $Log: settimeo.inc,v $
  28. Revision 1.8 2005/02/14 17:13:31 peter
  29. * truncate log
  30. Revision 1.7 2005/02/13 20:01:38 peter
  31. * include file cleanup
  32. }