[fpc-devel]A bug

Aleksey V. Vaneev picoder at sbis.komi.ru
Fri Jun 1 22:41:40 CEST 2001


Hello,

  Sorry for not reporting this bug in an ordinary way - I just don't
  have a web access right now.

  Just wanted to show you code that bugs in v1.1.

--------
type
        TCl = class
                public
                        a: AnsiString;

                        procedure load;
                end;

procedure TCl.load;

        procedure adddata (var buffer; l: dword);
        begin
                setlength (a, length (a) + l);
                move (buffer, (pointer (a) + length (a))^, l);
        end;

begin
        adddata (pointer(a)^,length (a));
end;

var
        Cl: TCl;

begin
        Cl := TCl.create;
cl.a:='34343';
cl.load;
cl.load;
writeln (cl.a);
end.
--------

  Seems to be that in "adddata" variable "a" is handled somehow
  incorrectly or something...

  There is also an inline problem in v1.1. That was for some time
  solved and now it appered again.

Best regards,
 Aleksey                          mailto:picoder at sbis.komi.ru






More information about the fpc-devel mailing list