bleakgrey / tootle

GTK-based Mastodon client for Linux
GNU General Public License v3.0
401 stars 61 forks source link

Segfault after clicking an image (Tries to and cannot make a directory) #274

Closed charliemikels closed 3 years ago

charliemikels commented 3 years ago

Apologies if this is a known issue. I briefly looked through the open Github issues and I did not quickly see a similar one.

What should happen:

(Not sure what the developer intention is, but) When I click a photo I expected it to open in a full size preview, likely in my system's default image viewer.

I have not yet tested what happens if you click a video or a post with more than one picture.

What happened instead:

Tootle hung for a brief moment and then closed.

How to reproduce:

  1. Open the app,
  2. Click on an image.

Build context:

Logs:

❯ tootle
** Message: 16:07:27.070: Build.vala:32: Tootle 1.0.0-alpha2
** Message: 16:07:27.070: Build.vala:33: Running on: Manjaro Linux Unknown
** Message: 16:07:27.070: Build.vala:34: Build prefix: "/usr"
** Message: 16:07:27.107: Accounts.vala:134: Loaded 1 accounts
** Message: 16:07:27.107: Accounts.vala:18: Switching to @Charlie@toot.cafe...
** Message: 16:07:27.109: Application.vala:147: Presenting MainWindow

** (tootle:25342): CRITICAL **: 16:07:27.177: tootle_instance_account_get_stream_url: assertion 'self != NULL' failed

** (tootle:25342): WARNING **: 16:07:27.314: Request.vala:94: No account was specified or found for GET: /api/v1/timelines/home?limit=12

** (tootle:25342): WARNING **: 16:07:27.314: Request.vala:94: No account was specified or found for GET: /api/v1/notifications?limit=12

** (tootle:25342): WARNING **: 16:07:27.314: Request.vala:94: No account was specified or found for GET: /api/v1/timelines/public?local=true&limit=12

** (tootle:25342): WARNING **: 16:07:27.314: Request.vala:94: No account was specified or found for GET: /api/v1/timelines/public?limit=12
** Message: 16:07:27.648: Accounts.vala:25: OK: Token is valid
** Message: 16:07:31.525: Desktop.vala:43: Downloading file: https://assets.toot.cafe/cache/media_attachments/files/105/595/551/812/399/893/original/53b2b4c2e2db2831.jpg...

** (tootle:25342): WARNING **: 16:07:31.587: Desktop.vala:76: Error: Error creating directory /home/charlie/Downloads/Tootle/assets.toot.cafe: No such file or directory

[1]    25342 segmentation fault (core dumped)  tootle
❯ 
XanderLeaDaren commented 3 years ago

I encountered the same bug and had to manually create a directory "Tootle" in my ~/Downloads/ directory. Problem solved.

Tootle has to create this directory by default when not present, in order to avoid this issue!

bleakgrey commented 3 years ago

This is already fixed in master (#240) and will be included in the next release.