segment: fix NULL pointer dereference in seg_write_header()
authorXi Wang <xi.wang@gmail.com>
Wed, 14 Nov 2012 07:52:32 +0000 (02:52 -0500)
committerMartin Storsjö <martin@martin.st>
Wed, 14 Nov 2012 10:33:27 +0000 (12:33 +0200)
commite8769b37fe8a841c0d28d3686c6d3cdecc542bc7
tree5b2ced9bf5a9011b51932971e3b6620af96561f9
parent26301caaa1aec5d71b564bff452147d6183370bf
segment: fix NULL pointer dereference in seg_write_header()

Since the pointer `oc' is NULL, oc->oformat->name will cause a null
pointer dereference.  This patch changes it to seg->oformat->name.

Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
libavformat/segment.c