summaryrefslogtreecommitdiffstats
path: root/video/dxva2.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2016-04-25 11:28:49 +0200
committerwm4 <wm4@nowhere>2016-04-25 11:28:49 +0200
commit021cb2c3870b9d0b2f2e03416702fc561f160c2b (patch)
tree659ac3ff21f104e722539651b6900717e570f5a3 /video/dxva2.c
parente232f1a731a9089a13d88def6c1f2c1a069a6353 (diff)
downloadmpv-021cb2c3870b9d0b2f2e03416702fc561f160c2b.tar.bz2
mpv-021cb2c3870b9d0b2f2e03416702fc561f160c2b.tar.xz
mp_image: allow passing NULL to mp_image_new_custom_ref()
A minor simplification. Most callers don't need this, and there's no good reason why the caller should provide an "initializer" like this. (This function calls mp_image_new_dummy_ref(), which has no reason for an initializer either.)
Diffstat (limited to 'video/dxva2.c')
-rw-r--r--video/dxva2.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/video/dxva2.c b/video/dxva2.c
index d6635ce0c6..cad3c54f72 100644
--- a/video/dxva2.c
+++ b/video/dxva2.c
@@ -72,8 +72,8 @@ struct mp_image *dxva2_new_ref(IDirectXVideoDecoder *decoder,
surface->decoder = decoder;
IDirectXVideoDecoder_AddRef(surface->decoder);
- struct mp_image *mpi = mp_image_new_custom_ref(&(struct mp_image){0},
- surface, dxva2_release_img);
+ struct mp_image *mpi =
+ mp_image_new_custom_ref(NULL, surface, dxva2_release_img);
if (!mpi)
abort();