Bug 410879 - OGG files are renamed to OGA
Summary: OGG files are renamed to OGA
Status: REPORTED
Alias: None
Product: kdeconnect
Classification: Applications
Component: common (show other bugs)
Version: 1.3.5
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Albert Vaca Cintora
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-08-13 14:58 UTC by Sefa Eyeoglu
Modified: 2019-09-05 07:30 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sefa Eyeoglu 2019-08-13 14:58:03 UTC
SUMMARY
When sending an OGG file from Dolphin (either over "Share->Send To Device" or just over "Send to <device> via KDE Connect") the file gets saved as "oga" on my Android. This happens with "real"/valid OGG files and also with text files renamed  to ".ogg", so this may be a problem with detecting the mime-type without looking at the data ("$ file textfile.ogg" reports ASCII text).

STEPS TO REPRODUCE
1. Find any ".ogg" file or create a file and save it with ".ogg" as the extension
2. Right-click the file in Dolphin
3. Click on Send to <device> via KDE Connect
4. Check notification on Android phone for the filename

OBSERVED RESULT
File gets saved as ".oga" instead of ".ogg"

EXPECTED RESULT
File gets saved as ".ogg"

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.16.4
KDE Frameworks Version: 5.60.0
Qt Version: 5.13.0
Kernel Version: 5.2.8-arch1-1-ARCH

ADDITIONAL INFORMATION
Sending an OGG file from my android phone to my desktop works without renaming the file.
Comment 1 Nicolas Fella 2019-09-05 07:30:19 UTC
TL;DR Android sucks

When saving the file Android automatically appends the file extension based on the mime type. So sending foo.png would end up as foo.png.png. To work around this we save the file as foo without extension so it ends up as foo.png. Some mime types (such as ogg) appear to have multiple possible extensions so the wrong one might get selected by Android. I'm not sure if we can do something about it, but I'll try