<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <p>I made a stupid error. My code:</p>
    <pre>  TFileObj = Class(TObject)
    [snip]
    Size: Integer;
    [snip]
    end;
....
procedure TForm1.FillDir(FileData : TSearchRec);
...
    FFIleObj.Size := FileData.Size;
...
</pre>
    but TSearchRec structure is:<br>
    <pre>  TRawbyteSearchRec = Record
    [snip]
    Size : Int64;
    [snip]
</pre>
    <p>IOW I assign an int64 to an integer.</p>
    <p>But when compiling I don't get any warning about that, and when
      the program runs there's no problem until the FileData.Size fits
      into an integer. When FileData.Size gets too large if compiled
      with -Co I get a range exception, if compiled without I just get
      wrong value for Size.</p>
    <p>Is that the intended behavior of compiler? <br>
    </p>
    <p>Platform Linux CentOs 7 - fpc 3.2.2</p>
    <p>Giuliano<br>
    </p>
  </body>
</html>