asfenc: return error on negative timestamp

According to the specification the timestamp is represented by a 32bit
unsigned.

CC: libav-stable@libav.org
iff: validate CMAP palette size

Fixes CVE-2013-2495

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>

CC: libav-stable@libav.org
mpeg12: do not fail on zero dimensions in the sequence header.

The total frame size is a combination of the 12 bits in the sequence
header and 2 more bits in the the sequence extension. While the
specification explicitly forbids the dimensions from the sequence header
from being 0 (thus ruling out multiples of 4096), such videos
apparrently exist in the wild so we should attempt to decode them.

Based on a patch by Michael Niedermayer <michaelni@gmx.at>

Fixes Bug 416.
print_options: do not generate docs for options without enc or dec flags

Those are not usable from the avtools, so mentioning them in the
manpages just confuses the reader.
Merge commit '50c449ac24fbb4c03c15d2e2026cef2204b80385'

* commit '50c449ac24fbb4c03c15d2e2026cef2204b80385':
  iff: validate CMAP palette size
  asfenc: return error on negative timestamp

Conflicts:
	libavformat/iff.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  print_options: do not generate docs for options without enc or dec flags
  mpeg12: do not fail on zero dimensions in the sequence header.

Conflicts:
	libavcodec/mpeg12.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
mpeg2: 12LSB w/h of 0 is not allowed in compliant videos thus this also needs AV_EF_COMPLIANT

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
append_packet_chunked: remove outcommented code

our variant works fine and should be better
also remove related unused variable

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>