Skip to content

Commit 45cf090

Browse files
author
Arnaud Bouchez
committed
fixed GPF with small number of stations (e.g. 400)
1 parent 1189cfe commit 45cf090

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

entries/abouchez/src/brcmormot.lpr

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -361,6 +361,7 @@ function TBrcMain.SortedText: RawUtf8;
361361
st: TRawByteStringStream;
362362
w: TTextWriter;
363363
ndx: TSynTempBuffer;
364+
tmp: TTextWriterStackBuffer;
364365
begin
365366
// compute the sorted-by-name indexes of all stations
366367
c := fList.Count;
@@ -371,7 +372,7 @@ function TBrcMain.SortedText: RawUtf8;
371372
FastSetString(result, nil, 1200000); // pre-allocate result
372373
st := TRawByteStringStream.Create(result);
373374
try
374-
w := TTextWriter.Create(st, @ndx.tmp, SizeOf(ndx.tmp));
375+
w := TTextWriter.Create(st, @tmp, SizeOf(tmp));
375376
try
376377
w.Add('{');
377378
n := ndx.buf;

0 commit comments

Comments
 (0)