mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-12-02 19:01:52 +00:00
Support polling on multiple fds
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include <pthread.h>
|
||||
#include <poll.h>
|
||||
#include <string>
|
||||
#include <limits>
|
||||
#include <atomic>
|
||||
@@ -43,6 +44,11 @@ extern bool zygisk_enabled;
|
||||
|
||||
int connect_daemon(bool create = false);
|
||||
|
||||
// Poll control
|
||||
using poll_callback = void(*)(pollfd*);
|
||||
void register_poll(const pollfd *pfd, poll_callback callback);
|
||||
void unregister_poll(int fd, bool auto_close);
|
||||
|
||||
extern std::atomic<int> logd_fd;
|
||||
int magisk_log(int prio, const char *fmt, va_list ap);
|
||||
void android_logging();
|
||||
|
||||
Reference in New Issue
Block a user