aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/wayland/wayland-client-helper.h
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-10-13 23:25:14 +0900
committerOphestra <cat@gensokyo.uk>2026-10-13 23:33:49 +0900
commit612533ee40aaeb97247db551ecbfc5026eb3ca41 (patch)
tree13ae364771f9bcf0def2b7401924d5b7c82af790 /internal/wayland/wayland-client-helper.h
parentfadb42ec8daeeb8a576582d274cd4aeb64e535c0 (diff)
all: use Linux kernel coding style
The Gitea web interface is no longer publicly accessible, so it no longer matters that this code style does not render well on Gitea. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/wayland/wayland-client-helper.h')
-rw-r--r--internal/wayland/wayland-client-helper.h64
1 files changed, 32 insertions, 32 deletions
diff --git a/internal/wayland/wayland-client-helper.h b/internal/wayland/wayland-client-helper.h
index ce67f6f6..09348be4 100644
--- a/internal/wayland/wayland-client-helper.h
+++ b/internal/wayland/wayland-client-helper.h
@@ -2,41 +2,41 @@
#include <sys/un.h>
typedef enum {
- HAKUREI_WAYLAND_SUCCESS,
- /* wl_display_connect_to_fd failed, errno */
- HAKUREI_WAYLAND_CONNECT,
- /* wl_registry_add_listener failed, errno */
- HAKUREI_WAYLAND_LISTENER,
- /* wl_display_roundtrip failed, errno */
- HAKUREI_WAYLAND_ROUNDTRIP,
- /* compositor does not implement wp_security_context_v1 */
- HAKUREI_WAYLAND_NOT_AVAIL,
- /* socket failed, errno */
- HAKUREI_WAYLAND_SOCKET,
- /* bind failed, errno */
- HAKUREI_WAYLAND_BIND,
- /* listen failed, errno */
- HAKUREI_WAYLAND_LISTEN,
+ HAKUREI_WAYLAND_SUCCESS,
+ /* wl_display_connect_to_fd failed, errno */
+ HAKUREI_WAYLAND_CONNECT,
+ /* wl_registry_add_listener failed, errno */
+ HAKUREI_WAYLAND_LISTENER,
+ /* wl_display_roundtrip failed, errno */
+ HAKUREI_WAYLAND_ROUNDTRIP,
+ /* compositor does not implement wp_security_context_v1 */
+ HAKUREI_WAYLAND_NOT_AVAIL,
+ /* socket failed, errno */
+ HAKUREI_WAYLAND_SOCKET,
+ /* bind failed, errno */
+ HAKUREI_WAYLAND_BIND,
+ /* listen failed, errno */
+ HAKUREI_WAYLAND_LISTEN,
- /* ensure pathname failed, implemented in conn.go */
- HAKUREI_WAYLAND_CREAT,
- /* socket for host server failed, implemented in conn.go */
- HAKUREI_WAYLAND_HOST_SOCKET,
- /* connect for host server failed, implemented in conn.go */
- HAKUREI_WAYLAND_HOST_CONNECT,
- /* cleanup failed, implemented in conn.go */
- HAKUREI_WAYLAND_CLEANUP,
+ /* ensure pathname failed, implemented in conn.go */
+ HAKUREI_WAYLAND_CREAT,
+ /* socket for host server failed, implemented in conn.go */
+ HAKUREI_WAYLAND_HOST_SOCKET,
+ /* connect for host server failed, implemented in conn.go */
+ HAKUREI_WAYLAND_HOST_CONNECT,
+ /* cleanup failed, implemented in conn.go */
+ HAKUREI_WAYLAND_CLEANUP,
} hakurei_wayland_res;
-hakurei_wayland_res hakurei_security_context_bind(
- char *socket_path,
- int server_fd,
- const char *app_id,
- const char *instance_id,
- int close_fd);
+hakurei_wayland_res hakurei_security_context_bind(char *socket_path,
+ int server_fd,
+ const char *app_id,
+ const char *instance_id,
+ int close_fd);
/* returns whether the specified size fits in the sun_path field of sockaddr_un */
-static inline bool hakurei_is_valid_size_sun_path(size_t sz) {
- struct sockaddr_un sockaddr;
- return sz <= sizeof(sockaddr.sun_path);
+static inline bool hakurei_is_valid_size_sun_path(size_t sz)
+{
+ struct sockaddr_un sockaddr;
+ return sz <= sizeof(sockaddr.sun_path);
};