* Fixed for 9879

git-svn-id: trunk@8760 -
This commit is contained in:
marco 2007-10-10 16:26:43 +00:00
parent 0021d0f27b
commit a19b22c48f

View File

@ -352,19 +352,23 @@ begin
begin
Node[SType]:=IntToStr(Ord(DataType));
DataNode:=Node.FirstChild;
Case DataType of
dtDWORD : DataNode.NodeValue:=IntToStr(PCardinal(@Data)^);
dtString : begin
SetLength(S,DataSize);
If (DataSize>0) then
Move(Data,S[1],DataSize);
DataNode.NodeValue:=S;
end;
dtBinary : begin
S:=BufToHex(Data,DataSize);
DataNode.NodeValue:=S;
end;
end;
Result:=DataNode<>Nil; // Bug 9879. Create child here?
If Result Then
begin
Case DataType of
dtDWORD : DataNode.NodeValue:=IntToStr(PCardinal(@Data)^);
dtString : begin
SetLength(S,DataSize);
If (DataSize>0) then
Move(Data,S[1],DataSize);
DataNode.NodeValue:=S;
end;
dtBinary : begin
S:=BufToHex(Data,DataSize);
DataNode.NodeValue:=S;
end;
end;
end;
end;
If Result then
begin
@ -711,11 +715,12 @@ Var
begin
N:=FindValueKey(OldName);
If (N<>Nil) then
result:=n<>nil;
If (Result) then
begin
N[SName]:=NewName;
FDirty:=True;
MaybeFlush;
N[SName]:=NewName;
FDirty:=True;
MaybeFlush;
end;
end;