BUG: Duplicate Images Output
I have motion-3.2.2_snap9. The bug seems to happen when motion is killed, and what seems to happen is that motion will create a duplicate of the last image saved for each thread and save it under a new filename. This seems to happen on all threads (2 composite cams and 1 usb). I have:'output_normal=best'. For example:
$ md5sum *.jpg
8e59728d4066c8f77879ccc13e9ed30f 1_20050805122646.jpg
8e59728d4066c8f77879ccc13e9ed30f 1_20050805122743.jpg
Test case
Environment
Motion version: |
3.2.2_snap9 |
ffmpeg version: |
0.4.9pre1 |
Shared libraries: |
curl, ffmpeg |
Server OS: |
Slackware 10.1, Kernel 2.6.12-git8 |
--
AndrewHamilton - 05 Aug 2005
Follow up
Does it do it when you have output_normal = on or first?
No, it only seems to happen on output_normal = best.
--
AndrewHamilton - 06 Aug 2005
Fix record
Yes. There was a logical bug. When motion was killed a variable called makemovie was set and this forces an artificial end of event. And the code that saves a the best jpeg from an event did not check if there had actually been a new event.
This modification in motion.c fixed it
if (cnt->new_img==NEWIMG_BEST && cnt->preview_max) {
preview_best(cnt);
cnt->preview_max = 0;
}
Fix included in motion-3.2.2
--
KennethLavrsen - 13 Aug 2005