Bug 364559 - Changing project settings and saving crashes the software
Summary: Changing project settings and saving crashes the software
Status: RESOLVED FIXED
Alias: None
Product: kdenlive
Classification: Applications
Component: Video Display & Export (show other bugs)
Version: 16.04.0
Platform: Arch Linux Linux
: NOR critical
Target Milestone: ---
Assignee: Jean-Baptiste Mardelle
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-20 18:32 UTC by Stefan Naumann
Modified: 2016-09-18 09:45 UTC (History)
3 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 Stefan Naumann 2016-06-20 18:32:13 UTC
When having a clip inside the project (in the timeline) changing the project settings, e.g. from 1080p29,997 to 1080p30 and saving the project crashes the software (before saving the file to disk)

Reproducible: Always

Steps to Reproduce:
1. Create a new project e.g. with 1080p 29,997 fps
2. Import a clip, drag it into the timeline, screw around
3. Project -> Project Settings; change to 1080p30
4. Hit Save in the icon bar
4(b) alternatively render the project

Actual Results:  
crashes the software (Segmentation fault); on rendering (4(b)) mlt will begin rendering the video, KDEnlive is crashed, mlt still renders; the resulting video is completely black

Expected Results:  
No crashing, but saving the project with the new settings; no crashing when rendering either.

Probably a very nasty bug inside the saving and XML-writing code.
Comment 1 Stefan Naumann 2016-06-20 19:39:21 UTC
Persists in 16.04.2
Comment 2 farid 2016-06-22 04:11:09 UTC
I am using 16.04.2 and I cannot reproduce. Do you have GPU processing turned on in the settings by any chance?
Comment 3 Stefan Naumann 2016-06-24 15:55:41 UTC
(In reply to farid from comment #2)
> I am using 16.04.2 and I cannot reproduce. Do you have GPU processing turned
> on in the settings by any chance?

Hello. 
I have no GPU-processing turned on. Did you save the project before changing the settings? Funny enough, I can't reproduce it on my laptop either, but it still persists on my PC.
Comment 4 Stefan Naumann 2016-06-24 17:24:00 UTC
Some specifics:
I've tried it using longer 1080p30 videos; tried it with a 20 second 1080p30-video. Both have the pretty much the same effect.

With the smaller video: Adding the first clip into the timeline did not lead to crashing, but rather adding the clip a second time - so maybe it's bound to some time-stamp? 

Another funny (or not so funny)-effect, is that saving drops the groups of clips. So when I insert video and audio split, then it will be group, when I insert it into the timeline. When changing the project settings this group is removed. 

Should I try to create a small enough video-sample to upload it as attachment, or is this not needed?
Comment 5 Wegwerf 2016-08-12 16:30:15 UTC
Stefan, can you re-check with current beta 16.07.90? Thank you for your efforts in advance?
Comment 6 YEK 2016-08-22 22:18:24 UTC
I am confirming this bug report.

I am experiencing the *exact* same bug the creator of this bug report (Stefan Naumann) mentioned in his initial bug report. Not similar, not almost the same, *exactly* the same bug. I could have easily submitted virtually an identical report. 

By the way, I'm running Kdenlive Version 16.04.3 which I installed from the Synaptic Package Manager on an Xubuntu derivative called Gallium OS 2.x on a Acer C720 Chromebook with 4gb of RAM.

I have copied and pasted most of the following from the beginning of this bug report.

When having a clip inside the project (in the timeline) changing the project settings, e.g. from 1080p29,997 to 1080p30 and saving the project crashes the software (before saving the file to disk) Reproducible: Always 

Steps to Reproduce: 

1. Create a new project e.g. with 1080p 29,997 fps 
2. Import a clip, drag it into the timeline, screw around 
3. Project -> Project Settings; change to 1080p30 
4. Hit Save in the icon bar 
4(b) alternatively render the project

Actual Results: crashes the software (Segmentation fault); on rendering (4(b)) mlt will begin rendering the video, KDEnlive is crashed, mlt still renders; the resulting video is completely black

Expected Results: No crashing, but saving the project with the new settings; no crashing when rendering either.
Comment 7 Stefan Naumann 2016-09-16 16:07:20 UTC
Still persists in 16.08.1 . 

What I found out: using round numbers as framerates (e.g. 25, 30, 60) does work fine. So probably the resolution-change is not the killer. Changing from 720p29,997 to 1080p59,997 then saving the project crashes KDEnlive. So probably the save-code and / or project-settings-change-code cannot handle switches from an float-framerate to a different float-framerate. 

I hope that helps.
Comment 8 YEK 2016-09-16 17:03:05 UTC
Thanks for posting your well-researched and thoughtful comment. We have clearly a confirmed bug.
Comment 9 Jean-Baptiste Mardelle 2016-09-16 18:36:23 UTC
Git commit 54554d178e00bcee5deb588a2ad1cb522d5e2c3a by Jean-Baptiste Mardelle.
Committed on 16/09/2016 at 18:36.
Pushed by mardelle into branch 'Applications/16.08'.

Fix crash when changing project fps while a clip was selected in timeline

M  +1    -0    src/timeline/customtrackview.cpp

http://commits.kde.org/kdenlive/54554d178e00bcee5deb588a2ad1cb522d5e2c3a
Comment 10 YEK 2016-09-16 22:36:23 UTC
Thanks for fixing that bug Jean-Baptiste. 

I am aware of another bug in Kdenlive 16.04 which I can easily replicate on my Linux machine. If I were to create a bug report would you or one of the other developers read it?
Comment 11 Jean-Baptiste Mardelle 2016-09-16 22:40:51 UTC
You're welcome, I hope this fixes the issue you had. Of course we try to read the bug reports, they are very welcome and helpful, especially if you can give us instructions to reproduce. We are a very small team so not all issues get solved as fast as we would like but please report your issue!
Comment 12 YEK 2016-09-18 08:41:12 UTC
Hi Jean-Baptiste,

Thanks for you kind, helpful and prompt response. I am not in a rush, but I have posted bug reports for other FOSS and often received "deafening silence." I am not complaining but I wanted to ensure someone would likely respond to one of my bug reports before I actually spent the time to create another one.

I just posted the other bug which I referred to above at https://bugs.kde.org/show_bug.cgi?id=368984

I have no idea if your bug fix for this issue would work on my machine because I am still running Kdenlive Version 16.04.3 which I installed from the Synaptic Package Manager. That is currently the most current version on the Synaptic Package Manager.

Previously I tried installed Kdenlive from a Terminal but although it installed, it would crash immediately upon launching. In other words, it was completely unusable for me.

Thanks,

Yekutiel
Comment 13 Jean-Baptiste Mardelle 2016-09-18 09:45:03 UTC
You should be able to easily test Kdenlive 16.08.x by using our official PPA. Instructions here:
https://kdenlive.org/download/

There were tons of stability & feature improvements since 16.04 so I really encourage you to test it.