Skip to content

Commit

Permalink
Set RM2FB_ACTIVE environment variable (#43)
Browse files Browse the repository at this point in the history
* Set RM2FB_ACTIVE environment variable

Multiple applications test this to determine if rm2fb is running
  • Loading branch information
Eeems authored May 25, 2024
1 parent 645456b commit c842fde
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions libs/rm2fb/Client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,11 @@ __libc_start_main(int (*_main)(int, char**, char**),

setenv("RM2FB_SHIM", "1", true);
setenv("RM2STUFF_RM2FB", "1", true);
if (getenv("RM2FB_ACTIVE") != nullptr) {
setenv("RM2FB_NESTED", "1", true);
} else {
setenv("RM2FB_ACTIVE", "1", true);
}

if (fb.mem == nullptr) {
std::cout << "No rm2fb shared memory\n";
Expand Down

0 comments on commit c842fde

Please sign in to comment.