Page 1 of 1

Crash when previewing images in archives/over SFTP [FIXED]

Posted: Wed Jan 06, 2021 12:35 pm
by fulgger
Hi there,

Ever since I've installed (1.2.9, build 3524, running on Catalina 10.15.7) I've had issues with previewing images over SFTP - NC just crashes each and every time I try doing that.

Today I've noticed the same behavior with images in zip files, again sudden crashes. They happen both if I press `Space` to preview the files, or View them with `F3, and change the mode to Preview. Needless to say, any of this didn't happen with the previous version.

I've attached the crash log, hopefully this will help debug the issue.

Thanks for continuing to maintain NC, it makes the Mac experience so much better.

Update: this happens when previewing zipped .txt files too (such as the one attached), assuming it happens whenever one tries to preview zipped data.

Re: Crash when previewing images in archives/over SFTP

Posted: Wed Jan 06, 2021 10:49 pm
by mike
Hi fulgger, thank you for the report.
I can reproduce the issue on my side on Catalina/x64, will try to fix it ASAP, as time permits.
The issue is indeed somewhere in the glue code between VFS and QuickLook, i.e. it doesn't matter which VFS is used.

Re: Crash when previewing images in archives/over SFTP

Posted: Thu Jan 07, 2021 7:58 am
by fulgger
Thanks mike, no rush!

Re: Crash when previewing images in archives/over SFTP

Posted: Thu Jan 07, 2021 10:39 pm
by mike
Well, I found and fixed the root cause in this particular case.
The cause was, by the looks of it, a stack overflow/corruption by a 256KB buffer placed on the stack in a code that wasn't touched in two years.
What actually happens (and why it works fine on BigSur/ARM64) is still a bit unclear to me, but seems to be a combination of a toolchain change and more aggressive optimisation levels.
I'll try to better understand the mechanics of the problem and look for similar potential issues before pushing an update.
Hopefully this weekend v1.2.9 will receive a fresh build.

Re: Crash when previewing images in archives/over SFTP

Posted: Sun Jan 10, 2021 10:38 pm
by mike
Updated v1.2.9 to build 3532, please pull this one via auto-update or manually.

Re: Crash when previewing images in archives/over SFTP [FIXED]

Posted: Mon Jan 11, 2021 7:13 am
by fulgger
Thanks for being so prompt mike! I've pulled the latest version and can confirm that it doesn't crash when previewing zipped files or files over SFTP anymore.

Cheers!