Files
weston/tests
Pekka Paalanen 7514bf7e45 tests: proper weston_test_surface_create()
struct weston_test_surface in the test harness' compositor plugin had no
tear down code, which lead to ASan report on alpha-blending test:

Direct leak of 64 byte(s) in 2 object(s) allocated from:
    #0 0x7f8931f10330 in __interceptor_malloc (/lib/x86_64-linux-gnu/libasan.so.5+0xe9330)
    #1 0x7f892d934425 in move_surface ../../git/weston/tests/weston-test.c:181
    #2 0x7f893159d8ed in ffi_call_unix64 (/lib/x86_64-linux-gnu/libffi.so.6+0x68ed)

While at it, let's do this properly for once:
- put the creation in a new function
- hook up to the weston_surface destroy signal so this actually gets
  freed (fixes the leak)
- check that we don't overwrite another surface role
- check that committed_private actually is ours
- set the surface label func so it gets properly listed in debugs and
  traces
- use the proper surface role setup call, so no-one stomps on anyones
  toes if a test makes a mistake by using a wrong wl_surface

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
2021-05-28 13:38:28 +03:00
..
2021-02-25 12:54:17 +02:00
2020-01-30 10:10:35 +00:00
2020-01-30 10:10:35 +00:00
2020-01-30 10:10:35 +00:00
2020-01-30 10:10:35 +00:00
2020-01-30 10:10:35 +00:00
2017-01-23 14:12:06 +02:00
2020-01-30 10:10:35 +00:00
2020-01-30 10:10:35 +00:00
2020-01-30 10:10:35 +00:00
2020-01-30 10:10:35 +00:00