Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

maxSize argument exceeds QByteArray size limit #286

Open
adanribeiro opened this issue Mar 21, 2021 · 8 comments
Open

maxSize argument exceeds QByteArray size limit #286

adanribeiro opened this issue Mar 21, 2021 · 8 comments

Comments

@adanribeiro
Copy link

adanribeiro commented Mar 21, 2021

Using glogg_1.1.4-1.1build1_amd64 on Ubuntu 20.04.2 LTS
QIODevice::read (QFile, "/home/ar/scripts/bkp.sql"): maxSize argument exceeds QByteArray size limit

This message return when I try to search for a string like Planonto "bkp.sql" (4GB).

There is any settings or known issues that I can consult about it?

@variar
Copy link
Contributor

variar commented Mar 22, 2021

Could it be that the bkp.sql file has only single line?

@adanribeiro
Copy link
Author

adanribeiro commented Mar 22, 2021

Sorry. For single line you mean "just one large and straight line"? No idea.
Unfortunely I can't manage how the file is created. It's sent to me through a client's third party software.
When I run glogg it tries for a while in the line 240. It seems a long string, but the fact there is a line 240 maybe can tell us something.

@variar
Copy link
Contributor

variar commented Apr 6, 2021

@GeadSolutions could you run wc -L bkp.sql This command should print the length of the longest line in the file bkp.sql.

glogg uses QByteArray/QString/QRegularExpression classes from Qt library. These classes can't handle huge lines. Changing this would require major refactoring as glogg currently need to keep the whole line in memory to do search pattern matching.

@adanribeiro
Copy link
Author

in: wc -L bkp.sql
out: 1043925 bkp.sql

@variar
Copy link
Contributor

variar commented Apr 6, 2021

It is definitely not a huge length. I've no more ideas at the moment. You could try klogg, I've rewritten a lot of glogg's code, so this particular issue might be fixed.

@adanribeiro
Copy link
Author

Well. I tried to run klogg with taht file but all system freezed and crashed. If you have another guess let me know, but I think perharps my system doesn't be prepared to make it properly.

@variar
Copy link
Contributor

variar commented Apr 7, 2021

Sorry for that. Looks like out of memory issue.

Could you restart klogg (without any files)? It might have created a crash dump, and on next start it should ask permission to upload it for analysis.

@adanribeiro
Copy link
Author

When I restarted it doesn't show me any report, so I created one for myself and sent to you. I've created this issue with the incoming content for anyone who want to consult too.

Crash Report on Github

danberindei pushed a commit to danberindei/glogg that referenced this issue Apr 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants