[vlc-commits] d3d11_adjust: Pass a non-const pointer to atomic_load

Martin Storsjö git at videolan.org
Mon Mar 19 13:36:09 CET 2018


vlc/vlc-3.0 | branch: master | Martin Storsjö <martin at martin.st> | Fri Dec 15 23:49:15 2017 +0200| [e527a6f38356f71dc262e7baf6b96b5b59e5e532] | committer: Steve Lhomme

d3d11_adjust: Pass a non-const pointer to atomic_load

This fixes compilation with clang, which previously errored
out with this message:

error: address argument to atomic operation must be a pointer to non-const _Atomic
      type ('const atomic_int *' (aka 'const _Atomic(int) *') invalid)
    int level = atomic_load(&p_level->level);
                ^           ~~~~~~~~~~~~~~~

(cherry picked from commit c51613372b52f5ae6039be67191b4b511a35e798)

> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=e527a6f38356f71dc262e7baf6b96b5b59e5e532
---

 modules/hw/d3d11/d3d11_filters.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/hw/d3d11/d3d11_filters.c b/modules/hw/d3d11/d3d11_filters.c
index 7a47891435..cc12e1f53c 100644
--- a/modules/hw/d3d11/d3d11_filters.c
+++ b/modules/hw/d3d11/d3d11_filters.c
@@ -135,7 +135,7 @@ static int assert_ProcessorInput(filter_t *p_filter, picture_sys_t *p_sys_src)
 
 static bool ApplyFilter( filter_sys_t *p_sys,
                          D3D11_VIDEO_PROCESSOR_FILTER filter,
-                         const struct filter_level *p_level,
+                         struct filter_level *p_level,
                          ID3D11VideoProcessorInputView *input,
                          ID3D11VideoProcessorOutputView *output,
                          const video_format_t *fmt)



More information about the vlc-commits mailing list