diff options
| author | Alex Yang <aycyang@google.com> | 2023-05-24 11:24:23 -0700 |
|---|---|---|
| committer | Alex Yang <aycyang@google.com> | 2023-06-27 14:08:25 -0700 |
| commit | 6d3334657180f3663b8d83636f4d1bc2097492d2 (patch) | |
| tree | e19fccaf09c724eabc614df8de258c92375f6a91 /tests | |
| parent | tests: manually wrap libc functions (diff) | |
| download | wayland-6d3334657180f3663b8d83636f4d1bc2097492d2.tar wayland-6d3334657180f3663b8d83636f4d1bc2097492d2.tar.gz wayland-6d3334657180f3663b8d83636f4d1bc2097492d2.tar.bz2 wayland-6d3334657180f3663b8d83636f4d1bc2097492d2.tar.lz wayland-6d3334657180f3663b8d83636f4d1bc2097492d2.tar.xz wayland-6d3334657180f3663b8d83636f4d1bc2097492d2.tar.zst wayland-6d3334657180f3663b8d83636f4d1bc2097492d2.zip | |
debug: Replace "@<id>" with "#<id>" in logs
Wayland debug logs resemble email addresses. This is a problem when
anonymizing logs from users. For example:
[2512874.343] xdg_surface@700.configure(333)
In the above log line, the substring "surface@700.config" can be
mistaken for an email address and redacted during anonymization.
Signed-off-by: Alex Yang <aycyang@google.com>
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/queue-test.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/queue-test.c b/tests/queue-test.c index 4129310..6562139 100644 --- a/tests/queue-test.c +++ b/tests/queue-test.c @@ -383,7 +383,7 @@ client_test_queue_destroy_with_attached_proxies(void) /* Check that the log contains some information about the attached * wl_callback proxy. */ log = map_file(client_log_fd, &log_len); - ret = snprintf(callback_name, sizeof(callback_name), "wl_callback@%u", + ret = snprintf(callback_name, sizeof(callback_name), "wl_callback#%u", wl_proxy_get_id((struct wl_proxy *) callback)); assert(ret > 0 && ret < (int)sizeof(callback_name) && "callback name creation failed (possibly truncated)"); @@ -456,7 +456,7 @@ client_test_queue_destroy_default_with_attached_proxies(void) /* Check that the log does not contain any warning about the attached * wl_callback proxy. */ log = maybe_map_file(client_log_fd, &log_len); - ret = snprintf(callback_name, sizeof(callback_name), "wl_callback@%u", + ret = snprintf(callback_name, sizeof(callback_name), "wl_callback#%u", wl_proxy_get_id((struct wl_proxy *) callback)); assert(ret > 0 && ret < (int)sizeof(callback_name) && "callback name creation failed (possibly truncated)"); |
