In my main app I have a few ways of "attaching" images to items and every now 
and then, I have a user who attaches bad JPGs. A bad JPG could be a zero byte 
file; a file with a JPG extension that really isn't a JPG (thank you, MS...); 
or some variation of a truncated JPG. I've worked out some validation code that 
can handle the first two and at least one type of truncated JPG but I'm looking 
to add one more test:  specifically, when the JPG header/metadata is intact but 
the actual number of compressed bytes stored on disk is less than it should be. 
Visually, you can usually see this because the JPG appears partially rendered. 
I've been poking around using the interwebs and the Google looking for some 
ideas that will allow me to determine this and was wondering if anyone here has 
any advice. (Right now, I'm playing around with the GDIPlusX classes but while 
I'm doing that I thought I'd throw this out to the list and see what comes 
back.)

TIA,

rk



_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/df1eef11e586a64fb54a97f22a8bd0441900310...@ackbwddqh1.artfact.local
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to