mirror of
https://github.com/xiaozhou233/JuiceAgent.git
synced 2026-12-05 13:05:53 +08:00
- ptrace-inject-cpp: remove the submodule, its .gitmodules entry and config section - includes/ptrace-inject-cpp: add the injection library sources, public header and LICENSE - includes/ptrace-inject-cpp: add CMakeLists defining the ptrace_inject static library - cmake: build includes/ptrace-inject-cpp on non-Windows instead of the submodule - docs: list the vendored library in the AGENTS.md layout
18 lines
542 B
C++
18 lines
542 B
C++
#pragma once
|
|
|
|
#include <string>
|
|
|
|
#include "ptrace_inject.h"
|
|
|
|
// Internal representation of ptrace_inject_options.
|
|
struct LogSink {
|
|
ptrace_inject_log_fn fn = nullptr;
|
|
void* user_data = nullptr;
|
|
};
|
|
|
|
// All of these do nothing when `sink` is null or `sink->fn` is null.
|
|
void log_message(const LogSink* sink, int level, const std::string& message);
|
|
void log_debug(const LogSink* sink, const std::string& message);
|
|
void log_info(const LogSink* sink, const std::string& message);
|
|
void log_warn(const LogSink* sink, const std::string& message);
|