Browse Source

* string -> shortstring

Michael VAN CANNEYT 2 years ago
parent
commit
74fdf0692c
6 changed files with 13 additions and 13 deletions
  1. 3 3
      rtl/unix/bunxovl.inc
  2. 1 1
      rtl/unix/genfunch.inc
  3. 2 2
      rtl/unix/genfuncs.inc
  4. 2 2
      rtl/unix/termiosh.inc
  5. 1 1
      rtl/unix/timezone.inc
  6. 4 4
      rtl/unix/ttyname.inc

+ 3 - 3
rtl/unix/bunxovl.inc

@@ -268,14 +268,14 @@ Begin
   FpOpen:=FpOpen(PAnsiChar(SystemPath),flags,MODE_FPOPEN);
   FpOpen:=FpOpen(PAnsiChar(SystemPath),flags,MODE_FPOPEN);
 end;
 end;
 
 
-Function  FpOpen    (path : String; flags : cInt):cInt;
+Function  FpOpen    (path : ShortString; flags : cInt):cInt;
 
 
 begin
 begin
  path:=path+#0;
  path:=path+#0;
  FpOpen:=FpOpen(@path[1],flags,MODE_FPOPEN);
  FpOpen:=FpOpen(@path[1],flags,MODE_FPOPEN);
 end;
 end;
 
 
-Function  FpOpen    (path : String; flags : cInt; Mode: TMode):cInt;
+Function  FpOpen    (path : ShortString; flags : cInt; Mode: TMode):cInt;
 
 
 begin
 begin
  path:=path+#0;
  path:=path+#0;
@@ -298,7 +298,7 @@ Begin
 End;
 End;
 
 
 
 
-Function  FpStat (path: String; var buf : stat): cInt;
+Function  FpStat (path: ShortString; var buf : stat): cInt;
 
 
 begin
 begin
  path:=path+#0;
  path:=path+#0;

+ 1 - 1
rtl/unix/genfunch.inc

@@ -14,7 +14,7 @@
 
 
  **********************************************************************}
  **********************************************************************}
 
 
-function CreateShellArgV(const prog:string):PPAnsiChar; deprecated;
+function CreateShellArgV(const prog:ShortString):PPAnsiChar; deprecated;
 
 
 function CreateShellArgV(const prog:RawByteString):PPAnsiChar; deprecated;
 function CreateShellArgV(const prog:RawByteString):PPAnsiChar; deprecated;
 
 

+ 2 - 2
rtl/unix/genfuncs.inc

@@ -37,7 +37,7 @@ begin
   InternalCreateShellArgV:=pp;
   InternalCreateShellArgV:=pp;
 end;
 end;
 
 
-function CreateShellArgV(const prog:string):PPAnsiChar;
+function CreateShellArgV(const prog:Shortstring):PPAnsiChar;
 begin
 begin
   CreateShellArgV:=InternalCreateShellArgV(@prog[1],length(prog));
   CreateShellArgV:=InternalCreateShellArgV(@prog[1],length(prog));
 end;
 end;
@@ -60,7 +60,7 @@ begin
    end;
    end;
 end;
 end;
 
 
-Function fpgetenv(name:string):PAnsiChar; [public, alias : 'FPC_SYSC_FPGETENV'];
+Function fpgetenv(name:Shortstring):PAnsiChar; [public, alias : 'FPC_SYSC_FPGETENV'];
 {
 {
   Searches the environment for a string with name p and
   Searches the environment for a string with name p and
   returns a PAnsiChar to it's value.
   returns a PAnsiChar to it's value.

+ 2 - 2
rtl/unix/termiosh.inc

@@ -30,6 +30,6 @@ Function  TCDrain     (fd:cint)     :cint;inline;
 Function  TCFlow      (fd,act:cint) :cint;inline;
 Function  TCFlow      (fd,act:cint) :cint;inline;
 Function  IsATTY      (Handle:cint) :cint;
 Function  IsATTY      (Handle:cint) :cint;
 Function  IsATTY      (var f:text)  :cint; inline;
 Function  IsATTY      (var f:text)  :cint; inline;
-function  TTYname     (Handle:cint):string;
-function  TTYname     (var F:Text) :string;
+function  TTYname     (Handle:cint):Shortstring;
+function  TTYname     (var F:Text) :Shortstring;
 
 

+ 1 - 1
rtl/unix/timezone.inc

@@ -252,7 +252,7 @@ begin
     TimeZoneDir:=TimeZoneDir+'/';
     TimeZoneDir:=TimeZoneDir+'/';
 end;
 end;
 
 
-function ReadTimezoneFile(fn:string) : Boolean;
+function ReadTimezoneFile(fn:shortstring) : Boolean;
 
 
   function decode(const l:longint):longint;
   function decode(const l:longint):longint;
   begin
   begin

+ 4 - 4
rtl/unix/ttyname.inc

@@ -14,7 +14,7 @@
 
 
  **********************************************************************}
  **********************************************************************}
 
 
-function TTYName(Handle:cint):string;
+function TTYName(Handle:cint):shortstring;
 {
 {
   Return the name of the current tty described by handle f.
   Return the name of the current tty described by handle f.
   returns empty string in case of an error.
   returns empty string in case of an error.
@@ -24,12 +24,12 @@ var
   myino     : ino_t;
   myino     : ino_t;
   st        : stat;
   st        : stat;
 
 
-  function mysearch(n:string): boolean;
+  function mysearch(n:shortstring): boolean;
   {searches recursively for the device in the directory given by n,
   {searches recursively for the device in the directory given by n,
     returns true if found and sets the name of the device in ttyname}
     returns true if found and sets the name of the device in ttyname}
   var dirstream : pdir;
   var dirstream : pdir;
       d         : pdirent;
       d         : pdirent;
-      name      : string;
+      name      : shortstring;
       st        : stat;
       st        : stat;
   begin
   begin
     dirstream:=fpopendir(n);
     dirstream:=fpopendir(n);
@@ -83,7 +83,7 @@ begin
 end;
 end;
 
 
 
 
-function TTYName(var F:Text):string;
+function TTYName(var F:Text):shortstring;
 {
 {
   Idem as previous, only now for text variables;
   Idem as previous, only now for text variables;
 }
 }