libei/test
Peter Hutterer 924341e174 ei: keep a cache of defunct objects to avoid spamming the log
Because of the asynchronous protocol, we may get this interaction

   server sends A->destroyed()
       client sends A->foo()
       client receives A->destroyed()
   server receives A->foo()
   server sends invalid_object_id(A)
       client receives invalid_object_id(A)

Previously we dropped the object after destroyed() and were thus
guaranteed to warn about the invalid object id for that same object
later.

Fix this by keeping a cache of defunct object IDs that we know about and
ignoring errors for recently dropped objects.

Every 20 ei_dispatch() calls we drop any defunct objects that were
unregistered more than 5 seconds ago.

Fixes #49
2023-11-09 12:47:06 +10:00
..
templates test: drop a bunch of unused imports 2023-02-15 08:20:01 +10:00
buildtest.c Purge libreis from the repo 2023-02-09 11:48:28 +10:00
buildtest.cc Add C++ header guards 2020-09-29 17:30:49 +10:00
conftest.py test: run pytest with xdist where available 2023-03-03 11:27:01 +10:00
eierpecken.c test: add the ability to add offsets to ei_now() 2023-11-09 12:47:06 +10:00
eierpecken.h test: add the ability to add offsets to ei_now() 2023-11-09 12:47:06 +10:00
eiproto.py.tmpl ei-scanner: expose version_arg and version_arg_for 2023-05-26 16:56:13 +10:00
meson.build test: set up a timer to trigger SIGALRM 2023-10-24 18:25:25 +10:00
test-ei-device.c test: make bug logs fatal by default 2023-11-09 10:15:38 +10:00
test-ei-seat.c test: switch to use ei_seat_bind_capabilities() 2023-05-10 12:21:40 +10:00
test-ei.c ei: keep a cache of defunct objects to avoid spamming the log 2023-11-09 12:47:06 +10:00
test-eis.c test: make bug logs fatal by default 2023-11-09 10:15:38 +10:00
test-main.c Remove empty trailing newlines from all files 2023-03-13 08:52:08 +10:00
test_oeffis.py test: rework the oeffis dbus tests to be pytest-compatible 2023-08-30 09:46:36 +10:00
test_protocol.py test: ensure all returned interface versions are 1 2023-06-07 23:08:16 +00:00
test_scanner.py ei-scanner: expose version_arg and version_arg_for 2023-05-26 16:56:13 +10:00
unit-tests.c Add SPDX identifiers to all source files 2022-03-03 00:27:36 +00:00