Add functions for listing clients
parent
8a7509bd3a
commit
79f26924ea
|
@ -134,6 +134,9 @@ bool nvnc_client_supports_cursor(const struct nvnc_client* client);
|
||||||
const char* nvnc_client_get_hostname(const struct nvnc_client* client);
|
const char* nvnc_client_get_hostname(const struct nvnc_client* client);
|
||||||
const char* nvnc_client_get_auth_username(const struct nvnc_client* client);
|
const char* nvnc_client_get_auth_username(const struct nvnc_client* client);
|
||||||
|
|
||||||
|
struct nvnc_client* nvnc_client_first(struct nvnc* self);
|
||||||
|
struct nvnc_client* nvnc_client_next(struct nvnc_client* client);
|
||||||
|
|
||||||
void nvnc_set_name(struct nvnc* self, const char* name);
|
void nvnc_set_name(struct nvnc* self, const char* name);
|
||||||
|
|
||||||
void nvnc_set_key_fn(struct nvnc* self, nvnc_key_fn);
|
void nvnc_set_key_fn(struct nvnc* self, nvnc_key_fn);
|
||||||
|
|
13
src/server.c
13
src/server.c
|
@ -1603,6 +1603,19 @@ const char* nvnc_client_get_auth_username(const struct nvnc_client* client) {
|
||||||
return client->username;
|
return client->username;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
EXPORT
|
||||||
|
struct nvnc_client* nvnc_client_first(struct nvnc* self)
|
||||||
|
{
|
||||||
|
return LIST_FIRST(&self->clients);
|
||||||
|
}
|
||||||
|
|
||||||
|
EXPORT
|
||||||
|
struct nvnc_client* nvnc_client_next(struct nvnc_client* client)
|
||||||
|
{
|
||||||
|
assert(client);
|
||||||
|
return LIST_NEXT(client, link);
|
||||||
|
}
|
||||||
|
|
||||||
EXPORT
|
EXPORT
|
||||||
bool nvnc_client_supports_cursor(const struct nvnc_client* client)
|
bool nvnc_client_supports_cursor(const struct nvnc_client* client)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue