~ubuntu-branches/debian/lenny/fpc/lenny

« back to all changes in this revision

Viewing changes to fpcdocs/bunixex/ex32.pp

  • Committer: Bazaar Package Importer
  • Author(s): Mazen Neifer, Torsten Werner, Mazen Neifer
  • Date: 2008-05-17 17:12:11 UTC
  • mfrom: (3.1.9 intrepid)
  • Revision ID: james.westby@ubuntu.com-20080517171211-9qi33xhd9evfa0kg
Tags: 2.2.0-dfsg1-9
[ Torsten Werner ]
* Add Mazen Neifer to Uploaders field.

[ Mazen Neifer ]
* Moved FPC sources into a version dependent directory from /usr/share/fpcsrc
  to /usr/share/fpcsrc/${FPCVERSION}. This allow installing more than on FPC
  release.
* Fixed far call issue in compiler preventing building huge binearies.
  (closes: #477743)
* Updated building dependencies, recomennded and suggested packages.
* Moved fppkg to fp-utils as it is just a helper tool and is not required by
  compiler.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
program Example31;
 
2
 
 
3
{ Program to demonstrate the FpDup2 function. }
 
4
 
 
5
uses BaseUnix;
 
6
 
 
7
var f : text;
 
8
    i : longint;
 
9
 
 
10
begin
 
11
  Assign (f,'text.txt');
 
12
  Rewrite (F);
 
13
  For i:=1 to 10 do writeln (F,'Line : ',i);
 
14
  if fpdup2 (output,f)=-1 then
 
15
    Writeln ('Dup2 Failed !');
 
16
  writeln ('This is written to stdout.');
 
17
  writeln (f,'This is written to the dup file, and flushed');
 
18
  flush(f);
 
19
  writeln;
 
20
  { Remove file. Comment this if you want to check flushing.}
 
21
  fpUnlink ('text.txt');
 
22
end.
 
 
b'\\ No newline at end of file'