summaryrefslogtreecommitdiff
path: root/libavformat/sdp.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-08-15 20:33:21 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-08-15 21:00:50 +0200
commitfb33bff990a8327f59d4c7c509bba1f62bbd6c5a (patch)
treec6f3ad232bed67c703999d78b3fcff66daa8c91d /libavformat/sdp.c
parent3bb22973518cbef28504e4d5b9fd74453cc3339c (diff)
parentf929ab0569ff31ed5a59b0b0adb7ce09df3fca39 (diff)
downloadffmpeg-fb33bff990a8327f59d4c7c509bba1f62bbd6c5a.tar.gz
Merge commit 'f929ab0569ff31ed5a59b0b0adb7ce09df3fca39'
* commit 'f929ab0569ff31ed5a59b0b0adb7ce09df3fca39': cosmetics: Write NULL pointer equality checks more compactly Conflicts: cmdutils.c ffmpeg_opt.c ffplay.c libavcodec/dvbsub.c libavcodec/dvdsubdec.c libavcodec/dvdsubenc.c libavcodec/dxa.c libavcodec/libxvid_rc.c libavcodec/mpegvideo.c libavcodec/mpegvideo_enc.c libavcodec/rv10.c libavcodec/tiffenc.c libavcodec/utils.c libavcodec/vc1dec.c libavcodec/zmbv.c libavdevice/v4l2.c libavformat/matroskadec.c libavformat/movenc.c libavformat/sdp.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/sdp.c')
-rw-r--r--libavformat/sdp.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/libavformat/sdp.c b/libavformat/sdp.c
index c53de90517..8c831f3607 100644
--- a/libavformat/sdp.c
+++ b/libavformat/sdp.c
@@ -189,7 +189,7 @@ static char *extradata2psets(AVCodecContext *c)
}
psets = av_mallocz(MAX_PSET_SIZE);
- if (psets == NULL) {
+ if (!psets) {
av_log(c, AV_LOG_ERROR, "Cannot allocate memory for the parameter sets.\n");
av_free(orig_extradata);
return NULL;
@@ -216,7 +216,7 @@ static char *extradata2psets(AVCodecContext *c)
sps = r;
sps_end = r1;
}
- if (av_base64_encode(p, MAX_PSET_SIZE - (p - psets), r, r1 - r) == NULL) {
+ if (!av_base64_encode(p, MAX_PSET_SIZE - (p - psets), r, r1 - r)) {
av_log(c, AV_LOG_ERROR, "Cannot Base64-encode %"PTRDIFF_SPECIFIER" %"PTRDIFF_SPECIFIER"!\n", MAX_PSET_SIZE - (p - psets), r1 - r);
av_free(psets);
@@ -250,7 +250,7 @@ static char *extradata2config(AVCodecContext *c)
return NULL;
}
config = av_malloc(10 + c->extradata_size * 2);
- if (config == NULL) {
+ if (!config) {
av_log(c, AV_LOG_ERROR, "Cannot allocate memory for the config info.\n");
return NULL;
}
@@ -457,7 +457,7 @@ static char *sdp_write_media_attributes(char *buff, int size, AVCodecContext *c,
av_log(c, AV_LOG_ERROR, "AAC with no global headers is currently not supported.\n");
return NULL;
}
- if (config == NULL) {
+ if (!config) {
return NULL;
}
av_strlcatf(buff, size, "a=rtpmap:%d MPEG4-GENERIC/%d/%d\r\n"