|
@@ -3899,7 +3899,10 @@ In case not, the value returned can be arbitrary.
|
|
|
{ convert existing string to an utf-8 string }
|
|
|
if not iswidestring then
|
|
|
begin
|
|
|
- ascii2unicode(@cstringpattern[1],len,patternw);
|
|
|
+ if len>0 then
|
|
|
+ ascii2unicode(@cstringpattern[1],len,patternw)
|
|
|
+ else
|
|
|
+ ascii2unicode(nil,len,patternw);
|
|
|
iswidestring:=true;
|
|
|
len:=0;
|
|
|
end;
|