WAR Corrupt JPEG data: 1 extraneous bytes before marker 0xd9

Forum for questions and support relating to the 1.25.x releases only.
christophe_y2k
Posts: 102
Joined: Mon Oct 12, 2009 8:47 am
Location: EUROPE-FRANCE-MANDELIEU

WAR Corrupt JPEG data: 1 extraneous bytes before marker 0xd9

Post by christophe_y2k » Sat Sep 10, 2011 5:54 am

Hello, have permanently this warning in my log.
With this IP Camera PT Foscam FI8918W under wifi 802.11b

This a ZM V1.25.SVN bug or an internal bug of this Foscam?

Thanks

Code: Select all

2011-09-10 07:48:12.376707	zmc_m2	19976	WAR	Corrupt JPEG data: 1 extraneous bytes before marker 0xd9	zm_jpeg.cpp	63
2011-09-10 07:48:12.293799	zmc_m2	19976	WAR	Corrupt JPEG data: 2 extraneous bytes before marker 0xd9	zm_jpeg.cpp	63
2011-09-10 07:48:12.258448	zmc_m2	19976	WAR	Corrupt JPEG data: 1 extraneous bytes before marker 0xd9	zm_jpeg.cpp	63
2011-09-10 07:48:11.089237	zmc_m2	19976	WAR	Corrupt JPEG data: 1 extraneous bytes before marker 0xd9	zm_jpeg.cpp	63
2011-09-10 07:48:10.005381	zmc_m2	19976	WAR	Corrupt JPEG data: 2 extraneous bytes before marker 0xd9	zm_jpeg.cpp	63
...
...
...

gmar_87
Posts: 69
Joined: Sat Aug 13, 2011 11:38 pm
Location: Melbourne, Australia

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by gmar_87 » Sat Sep 10, 2011 8:47 am

I don't think this is 1.25.0 related. I was also receiving this error in the logs in 1.24.4, but i would also like to know how to fix!

christophe_y2k
Posts: 102
Joined: Mon Oct 12, 2009 8:47 am
Location: EUROPE-FRANCE-MANDELIEU

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by christophe_y2k » Sun Sep 11, 2011 9:14 pm

Hello,

the only way i found on another forum (i no try)
is to desactivate the error logging in the libjpeg library that return this error
but with my other cam no errors this is foscam relevant

wait and see...

koolb
Posts: 14
Joined: Tue Oct 04, 2011 3:30 am

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by koolb » Sun Oct 09, 2011 7:02 pm

I was getting this one my newly added foscam monitors. I just disabled them with the following code @ zm_jpeg.cpp:63

(zmerr->pub.format_message)( cinfo, buffer );
if (!strstr(buffer, "Corrupt JPEG data:")) // add this line before warning. It was quite annoying.
Warning( "%s", buffer );

There's probably a better way. Have not done a deep dive into the code. Busy setting up monitors.

gmar_87
Posts: 69
Joined: Sat Aug 13, 2011 11:38 pm
Location: Melbourne, Australia

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by gmar_87 » Mon Oct 10, 2011 10:09 pm

How to analyse JPEG from Foscam cameras to check for corrupt data? I want to provide Foscam with proof so they may investigate the issue.

px03afk
Posts: 46
Joined: Wed Nov 30, 2011 4:53 pm

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by px03afk » Tue Dec 27, 2011 5:10 pm

Is there any progress on this problem. I've only just installed some Foscam cameras and have exactly the same issue.

leyton01
Posts: 5
Joined: Mon Dec 26, 2011 11:53 am

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by leyton01 » Sat Dec 31, 2011 4:19 am

Similar issue here

*Foscam FI8918W on 1.2.5

koolb
Posts: 14
Joined: Tue Oct 04, 2011 3:30 am

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by koolb » Sat Dec 31, 2011 5:00 am

Just got an email asking how I fixed this. Again, simply add the following line just before the Warning(...) line at or near line 63 of zm_jpeg.cpp:

if (!strstr(buffer, "Corrupt JPEG data:")) // this is the new line of code that will eliminate the Foscam 8918W camera...

The above code instructs the program to only send warnings if the message does *not* contain the string "Corrupt JPEG data:".

Once this is done, simply run:

make && sudo make install # from your zoneminder code directory. A zm restart may be in order to activate the change.

leyton01
Posts: 5
Joined: Mon Dec 26, 2011 11:53 am

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by leyton01 » Sat Dec 31, 2011 6:42 am

that was me :)

I hadn't done the make and make install to include the change - working now thanks!

px03afk
Posts: 46
Joined: Wed Nov 30, 2011 4:53 pm

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by px03afk » Sat Dec 31, 2011 6:41 pm

It's a good workaround but should it really be necessary? Surely there is something wrong somewhere else to need such a fix.

koolb
Posts: 14
Joined: Tue Oct 04, 2011 3:30 am

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by koolb » Sun Feb 19, 2012 3:54 am

@px03afk - Yes there's some extraneous data in the jpg and that's probably a bug that needs to be fixed. However firmware changes are a bit more risky so I prefer to work around it until "they" get it working someday. For the price/performance I am not complaining if this is the only issue I have had. I did notice that I'm getting more 1 frame signal drops. Could be the cam or my overloaded wireless network using multiple cams/puters/printers. However the trouble of running the new line (which is more suseptible to very close lighting strike on frying quipment) I am also willing to ignore for now with some workarounds.

px03afk
Posts: 46
Joined: Wed Nov 30, 2011 4:53 pm

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by px03afk » Sun Feb 19, 2012 10:06 pm

Don't disagree at all about the price/performance and at least there is a workaround, which as far as I am cocerned provides me with a working solution. I've been using ZoneMinder for about a month now and I think it is a great product. Only problem I've been having is understanding how to set up the motion sensing so it catches everything I want and ignores what I don't want, but that is something I'm working on.

koolb
Posts: 14
Joined: Tue Oct 04, 2011 3:30 am

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by koolb » Sun Feb 26, 2012 11:27 pm

We are always tuning our zones. This warning has *nothing* to do with motion detection at all. Just a few errounous bytes on the jpeg envelope, not the contents.

User avatar
Blazer
Posts: 234
Joined: Sun Jun 05, 2005 12:57 pm

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by Blazer » Sun Mar 11, 2012 5:26 am

I have seen this error in my logs across many versions of Zoneminder, on different servers, operating systems, etc. I think it is an issue with libjpeg, but it has also occured to me with various versions of libjpeg as well. I have scratched my head many times trying to figure this out and finally gave up. I think it may (or may not) be related to my cams randomly going black for a moment, both USB and IP cams. I just give up and accept it now, LOL.

User avatar
dvarapala
Posts: 53
Joined: Sat Nov 06, 2010 2:30 pm

Re: WAR Corrupt JPEG data: 1 extraneous bytes before marker

Post by dvarapala » Sun Mar 11, 2012 6:34 pm

It's definitely a camera firmware issue. Other brands of cameras also have this bug (or perhaps the Foscam units with this bug are OEM'd by Arecont Vision?)

My solution was basically the same as mentioned above: add an if statement to the libjpeg code to suppress the error message.

http://www.zoneminder.com/forums/viewto ... 410#p70410

Post Reply

Who is online

Users browsing this forum: No registered users and 15 guests