Possible bug with setting StripQuotes in TIniFile.Create
Original Reporter info from Mantis: jk987
-
Reporter name:
Original Reporter info from Mantis: jk987
- Reporter name:
Description:
When I'm looking into IniFiles unit then I can see there something like:
constructor TIniFile.Create(const AFileName: string; AOptions : TIniFileOptions = []);
var
slLines: TStringList;
begin
FBOM := '';
If Not (self is TMemIniFile) then
StripQuotes:=True;
inherited Create(AFileName,AOptions);
...
I suppose that the idea of "If Not (self is TMemIniFile) then StripQuotes:=True;" part was that after calling "ini := TIniFile.Create(filename);" the StripQuotes property should be automatically set to true.
But I think that the following line "inherited Create(AFileName,AOptions);" resets it to false because default options are "[]". So the whole "if self is not TMemIniFile" idea goes to nowhere.
Additional information:
I haven't investigated it too much yet.
I was only wondering why application rebuilt in upgraded Lazarus (1.6.4) behaves differently when reading quoted strings from ini-files than two years ago (Lazarus 1.6.0 / FPC 3.0.0).
Mantis conversion info:
- Mantis ID: 33052
- OS: Windows
- OS Build: 7
- Version: 3.0.2
- Fixed in version: 3.1.1
- Fixed in revision: 38018 (#d1bba7ec)
- Target version: 3.2.0