# HG changeset patch # User Paul Boddie # Date 1678203883 -3600 # Node ID 4a5c85bf5bb21b6e44517bea4c6e9b5ab627465c # Parent 26baf4c23b927d8cb2ee173e37acabffce906a68 Changed the internal pager capability name to avoid potential conflicts. diff -r 26baf4c23b92 -r 4a5c85bf5bb2 libexec/include/exec/common.h --- a/libexec/include/exec/common.h Tue Mar 07 00:43:52 2023 +0100 +++ b/libexec/include/exec/common.h Tue Mar 07 16:44:43 2023 +0100 @@ -1,7 +1,7 @@ /* * Common structures and functions. * - * Copyright (C) 2022 Paul Boddie + * Copyright (C) 2022, 2023 Paul Boddie * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -29,6 +29,12 @@ EXTERN_C_BEGIN +/* Common definitions. */ + +#define ENV_INTERNAL_PAGER_NAME "intpager" + + + /* Auxiliary vector key-value pair. */ struct auxv_entry diff -r 26baf4c23b92 -r 4a5c85bf5bb2 libexec/lib/src/process_creating.cc --- a/libexec/lib/src/process_creating.cc Tue Mar 07 00:43:52 2023 +0100 +++ b/libexec/lib/src/process_creating.cc Tue Mar 07 16:44:43 2023 +0100 @@ -21,6 +21,7 @@ #include +#include #include #include #include @@ -229,7 +230,7 @@ mapping the capability and encoded in the entry below. */ l4re_env_cap_entry_t rm_init_caps[] = { - l4re_env_cap_entry_t("server", _ipc_gate_cap, L4_CAP_FPAGE_RWS), + l4re_env_cap_entry_t(ENV_INTERNAL_PAGER_NAME, _ipc_gate_cap, L4_CAP_FPAGE_RWS), l4re_env_cap_entry_t() }; diff -r 26baf4c23b92 -r 4a5c85bf5bb2 libexec/rm/region_mapper.cc --- a/libexec/rm/region_mapper.cc Tue Mar 07 00:43:52 2023 +0100 +++ b/libexec/rm/region_mapper.cc Tue Mar 07 16:44:43 2023 +0100 @@ -65,13 +65,13 @@ /* Start the pager. */ printf("Initialising pager...\n"); - printf("Pager capability: %lx\n", l4re_env_get_cap("server")); + printf("Pager capability: %lx\n", l4re_env_get_cap(ENV_INTERNAL_PAGER_NAME)); printf("Main thread: %lx\n", l4re_env()->main_thread); /* Initialise the server, enabling notifications. */ ResourceServer server(&exec_pager); - long err = server.bind("server"); + long err = server.bind(ENV_INTERNAL_PAGER_NAME); if (err) {