Keidan / HexViewer

(GPL) Android Hex Viewer is a FREE software.
GNU General Public License v3.0
163 stars 25 forks source link

always when I open a file I get an 'not enough memory' error #273

Closed jensMF closed 1 year ago

jensMF commented 1 year ago

Hi,

I have a Shift6mq with android 10. Always when I try to open a file with or in HexViewer, I get an error that says 'Unable to execute the command because there's not enough memory for this app'

A log with two tries, one with partially open says this:

20231017 [030030PM]:
(FileHelper) -> Get filename for uri: 'content://com.android.externalstorage.documents/document/home%3AHex.txt'
20231017 [030030PM]:
(FileHelper) -> Uri scheme equals to content
20231017 [030030PM]:
(FileHelper) -> Filename DISPLAY_NAME cursor index: '2'
20231017 [030030PM]:
(FileHelper) -> Filename DISPLAY_NAME cursor value: 'Hex.txt'
20231017 [030030PM]:
(FileHelper) -> Filename result: 'Hex.txt'
20231017 [030030PM]:
(FileHelper) -> Get file size for uri: 'content://com.android.externalstorage.documents/document/home%3AHex.txt'
20231017 [030030PM]:
(FileHelper) -> Get file size: '37'
20231017 [030030PM]:
(FileHelper) -> Get file size for uri: 'content://com.android.externalstorage.documents/document/home%3AHex.txt'
20231017 [030030PM]:
(FileHelper) -> Get file size: '37'
20231017 [030030PM]:
(Open) -> Open file: '0^0^content://com.android.externalstorage.documents/document/home%3AHex.txt'
20231017 [030030PM]:
(Open) -> Low memory detected
20231017 [030035PM]:
(FileHelper) -> Get filename for uri: 'content://com.android.externalstorage.documents/document/home%3AHex.txt'
20231017 [030035PM]:
(FileHelper) -> Uri scheme equals to content
20231017 [030035PM]:
(FileHelper) -> Filename DISPLAY_NAME cursor index: '2'
20231017 [030035PM]:
(FileHelper) -> Filename DISPLAY_NAME cursor value: 'Hex.txt'
20231017 [030035PM]:
(FileHelper) -> Filename result: 'Hex.txt'
20231017 [030035PM]:
(FileHelper) -> Get file size for uri: 'content://com.android.externalstorage.documents/document/home%3AHex.txt'
20231017 [030035PM]:
(FileHelper) -> Get file size: '37'
20231017 [030035PM]:
(FileHelper) -> Get file size for uri: 'content://com.android.externalstorage.documents/document/home%3AHex.txt'
20231017 [030035PM]:
(FileHelper) -> Get file size: '37'
20231017 [030035PM]:
(PartialOpen) -> Open file 'Hex.txt', sequential: false, rsize: 37, size: 37, start: 0, end: 0
20231017 [030056PM]:
(Open) -> Low memory detected

What can I do?

Keidan commented 1 year ago

Hi,

Thank you for your contribution.

I don't have this smartphone and unfortunately I can't reproduce this problem on the emulator running Android 10.

I'll add more traces in the next version. I'll also add an option to disable the protection on the low memory event "Settings" -> "Memory threshold" -> "Disable"

Have you tried killing running processes to free up memory on your smartphone?

Keidan commented 1 year ago

Hello,

I'm closing this issue to finalize my Milestone but feel free to reopen it, if you still have the problem with version 1.48 (or if you have more information).

jensMF commented 11 months ago

For me it works now.

Keidan commented 11 months ago

Thanks for your feedback :)