slapperwan / gh4a

Github client for Android
Apache License 2.0
1.72k stars 221 forks source link

Crash on viewing zero byte files in some devices #844

Open twse opened 6 years ago

twse commented 6 years ago

Expected Behavior: Program does not crash.

Actual Behavior: When viewing a zero-byte file from within repositories, the program crashes.

How to reproduce the bug:

  1. Open the app.
  2. Go to any repository with zero-byte files.
  3. Select a zero-byte file.

Tested specs

maniac103 commented 6 years ago

I can't repro the problem with a recent master build and https://github.com/slapperwan/gh4a/blob/master/testempty.txt - what version are you using?

twse commented 6 years ago

I'm using OctoDroid version 4.3.1 running under Android 4.1.2.

maniac103 commented 6 years ago

Can you share the URL of the file you're attempting to view when the crash happened? Maybe there's more to it than the emptiness.

twse commented 6 years ago

The URL to file (testempty.txt) is mentioned in the second post.

maniac103 commented 6 years ago

The URL to file (testempty.txt) is mentioned in the second post.

Err, yes, I know, I posted that link. As mentioned, it does not crash for me when visiting that file though ... so it does crash for you when visiting exactly that file?

twse commented 6 years ago

The crash happened on Pantech IM-A840SP.