ezcgi.inc 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. {
  2. $Id$
  3. This file is part of the Free Pascal run time library.
  4. Copyright (c) 1999-2000 by Michael Van Canneyt
  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. Uses
  12. {$ifdef ver1_0}
  13. Linux
  14. {$else}
  15. Unix
  16. {$endif}
  17. ;
  18. { Declared EXPLICITLY with Ansistring, so NO mistaking is possible }
  19. Function Getenv (Var EnvVar : AnsiString): AnsiString;
  20. Var P : Pchar;
  21. begin
  22. // Linux version returns pchar.
  23. p:={$ifdef ver1_0}Linux{$else}Unix{$endif}.getenv(EnvVar);
  24. if P<>nil then
  25. getenv:=strpas(p)
  26. else
  27. getenv:='';
  28. end;
  29. {
  30. $Log$
  31. Revision 1.4 2001-04-08 11:26:03 peter
  32. * update so it can be compiled by both 1.0.x and 1.1
  33. Revision 1.3 2001/01/21 20:45:09 marco
  34. * Rename fest II FCL version.
  35. Revision 1.2 2000/10/26 22:30:21 peter
  36. * freebsd update
  37. * classes.rst
  38. Revision 1.1.2.1 2000/10/25 12:36:24 marco
  39. * Split up Freebsd/Unix/Linux for Fixes FCL
  40. Revision 1.1 2000/07/13 06:31:32 michael
  41. + Initial import
  42. Revision 1.7 2000/02/15 22:03:38 sg
  43. * Inserted wrong copyright notice ;) Fixed.
  44. Revision 1.6 2000/02/15 21:57:51 sg
  45. * Added copyright notice and CVS log tags where necessary
  46. }