variar / klogg

Really fast log explorer based on glogg project
https://klogg.filimonov.dev
GNU General Public License v3.0
2.4k stars 208 forks source link

Crash while opening 6GB. #265

Closed KhalilMohammad closed 3 years ago

KhalilMohammad commented 3 years ago

Details for the issue

What did you do?

I tried opening 6GB file.


Crash id aef317d2-60c1-4644-8180-86534e67e2fe

Useful extra information

Klogg version 21.02.0.828 (built from commit 9bf68ff) [built for x86_64-little_endian-llp64] running on Windows 10 Version 2009 (winnt/10.0.19043) [x86_64] and Qt 5.15.2

variar commented 3 years ago

Sentry issue KLOGG-3R

Thread 33340 Crashed:

0   KERNELBASE.dll                  0x7ffa04734b59      RaiseException
1   VCRUNTIME140.dll                0x7ff9bf7f621f      _CxxThrowException (throw.cpp:74)
2   Qt5Core.dll                     0x7ff93d849ace      qBadAlloc
3   Qt5Core.dll                     0x7ff93d8ef5f5      QString::fromLatin1_helper
4   Qt5Core.dll                     0x7ff93da505d8      QWinRegistryKey::stringValue
5   Qt5Core.dll                     0x7ff93da52fde      QTextDecoder::toUnicode
6   klogg.exe                       0x7ff61213f94b      LogData::getLinesFromFile (logdata.cpp:477)
7   klogg.exe                       0x7ff61213f4d9      LogData::doGetExpandedLines (logdata.cpp:422)
8   klogg.exe                       0x7ff6121440fe      AbstractLogData::getExpandedLines (abstractlogdata.cpp:68)
9   klogg.exe                       0x7ff6120ecfc8      AbstractLogView::drawTextArea (abstractlogview.cpp:1733)
10  klogg.exe                       0x7ff6120e7ad2      AbstractLogView::paintEvent (abstractlogview.cpp:792)

The stack trace has 117 frames. Might be too deep?

KhalilMohammad commented 3 years ago

Also, note that it opens in UltraEdit and EmEditor. Both are commercial products. I have not tried another freemium product yet.

variar commented 3 years ago

@KhalilMohammad could you check build 21.04.0.844? I suspect that some lines in that file are more that 1'000'000 characters, and unfortunately QString can't handle such strings. I've added a check for this case. In case there is enough RAM to read such string as bytes, klogg should not attempt to convert it to Unicode and so avoid crashing.

variar commented 3 years ago

I see no more dumps from recent versions. Closing for now.