AppImageCommunity / libappimage

Implements functionality for dealing with AppImage files
https://appimage.org
Other
46 stars 29 forks source link

appimage_shall_not_be_integrated and others fail on symlinked desktop files #142

Closed TheAssassin closed 4 years ago

TheAssassin commented 4 years ago

First discovered with:

The listed AppImages use symlinks to another file as their main desktop file in the AppDir root directory. XdgUtils's desktop file parser (or whatever breaks here) silently ignores that, however, the error is swallowed unnoticed. When using entry.get(), the fallback is always returned, which leads to X-AppImage-Integrate not being interpreted at all.

Now, of course there's some symlink resolving missing in that method, that's quite obvious. IMO the whole check should be implemented in the AppImage class anyway, since we have this check more than once in our code base, which is always a bad idea.

It's however interesting how opening a symlink and reading its contents just yield to an empty desktop file. And it's bad style that XdgUtils doesn't even complain about the desktop file being broken (as in, empty): if there's an error, at least some logging of any kind should occur.

I've spent hours trying to find out where the root cause of the error is. This could've been avoided by not making as many assumptions.

JustTNE commented 4 years ago

I'm still having this issue on manjaro testing :thinking:

TheAssassin commented 4 years ago

You need to provide more information. The least you can do is write how you use libappimage, what version you use, ...