clean up and standardize types across the codebase, unify atomic operations, improve UTF-8 handling throughout the system, remove obsolete input and named queue interfaces, redesign process preparation and creation, tighten IPC and service boundaries, improve error handling and reliability, minor documentation cleanup, fix doom surfaces, fix panic in ini parsing.
This commit is contained in:
1 parent
899225f551
commit
c0ad63c27f
226 files changed
+6562
-4147
No files matched your search
@@ -1,5 +1,6 @@
|
||||
// Native user-raised exception smoke test.
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
#include <stddef.h>
|
||||
#include <ntlite/exception.h>
|
||||
@@ -48,7 +49,7 @@ static void fail(const char* message) {
|
||||
}
|
||||
|
||||
// Fails the test with one status value.
|
||||
static void fail_status(const char* what, uint32_t status) {
|
||||
static void fail_status(const char* what, KSTATUS status) {
|
||||
print("native_raise_exception_smoke: ");
|
||||
print(what);
|
||||
print(" status=");
|
||||
@@ -73,14 +74,14 @@ static void expect_status(const char* what, uint32_t got, uint32_t expected) {
|
||||
|
||||
// Reads aggregate exception counters.
|
||||
static void query_exception_stats(SYS_EXCEPTION_STATS* out) {
|
||||
uint32_t status = SysQueryKernelStats(SYS_KERNEL_STATS_EXCEPTION, out, sizeof(*out), 0);
|
||||
KSTATUS status = SysQueryKernelStats(SYS_KERNEL_STATS_EXCEPTION, out, sizeof(*out), 0);
|
||||
expect_status("query exception stats", status, NTLSTATUS_SUCCESS);
|
||||
if (out->Size != sizeof(*out) || out->Version != SYS_STATS_VERSION)
|
||||
fail("exception stats ABI mismatch");
|
||||
}
|
||||
|
||||
// Handles the user-raised exception and verifies its native record payload.
|
||||
static int smoke_handler(SYS_EXCEPTION_RECORD* record, SYS_USER_CONTEXT* context, void* userContext) {
|
||||
static uint32_t smoke_handler(SYS_EXCEPTION_RECORD* record, SYS_USER_CONTEXT* context, void* userContext) {
|
||||
if (userContext != (void*)(uintptr_t)0x111E)
|
||||
fail("handler context mismatch");
|
||||
if (!record || !context)
|
||||
@@ -123,7 +124,7 @@ int main(void) {
|
||||
request.ParameterCount = 2;
|
||||
request.Parameters = args;
|
||||
|
||||
uint32_t status = SysRaiseException(&request);
|
||||
KSTATUS status = SysRaiseException(&request);
|
||||
expect_status("raise exception", status, NTLSTATUS_SUCCESS);
|
||||
if (gHandlerHits != 1)
|
||||
fail("handler was not called exactly once");
|
||||
|
||||
Reference in new issue
Block a user