~ubuntu-branches/ubuntu/dapper/fpc/dapper

« back to all changes in this revision

Viewing changes to fcl/netwlibc/custapp.inc

  • Committer: Bazaar Package Importer
  • Author(s): Carlos Laviola
  • Date: 2005-05-30 11:59:10 UTC
  • mfrom: (1.2.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20050530115910-x5pbzm4qqta4i94h
Tags: 2.0.0-2
debian/fp-compiler.postinst.in: forgot to reapply the patch that
correctly creates the slave link to pc(1).  (Closes: #310907)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
{
 
2
    $Id: custapp.inc,v 1.2 2005/02/14 17:13:16 peter Exp $
 
3
    This file is part of the Free Pascal run time library.
 
4
    Copyright (c) 2004 by the Free Pascal development team
 
5
 
 
6
    Linux version of custom app object routines.
 
7
 
 
8
    See the file COPYING.FPC, included in this distribution,
 
9
    for details about the copyright.
 
10
 
 
11
    This program is distributed in the hope that it will be useful,
 
12
    but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
14
 
 
15
 **********************************************************************}
 
16
 
 
17
Procedure SysGetEnvironmentList(List : TStrings;NamesOnly : Boolean);
 
18
 
 
19
Var
 
20
  P : PPChar;
 
21
  S : String;
 
22
  I : Integer;
 
23
 
 
24
begin
 
25
  List.Clear;
 
26
  P:=EnvP;
 
27
  if (P<>Nil) then
 
28
    While (P^<>Nil) do
 
29
      begin
 
30
      S:=StrPas(P^);
 
31
      If NamesOnly then
 
32
        begin
 
33
        I:=Pos('=',S);
 
34
        If (I>0) then
 
35
          S:=Copy(S,1,I-1);
 
36
        end;
 
37
      List.Add(S);
 
38
      Inc(P);
 
39
    end;
 
40
end;
 
41
 
 
42
{
 
43
  $Log: custapp.inc,v $
 
44
  Revision 1.2  2005/02/14 17:13:16  peter
 
45
    * truncate log
 
46
 
 
47
}
 
48