Skip to content

Commit

Permalink
COMP: Provide getpid, getuid shims for WASI
Browse files Browse the repository at this point in the history
  • Loading branch information
thewtex authored and bourdaisj committed May 15, 2024
1 parent bf53a05 commit 4c41214
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Modules/ThirdParty/GDCM/src/gdcm/Utilities/gdcmuuid/gen_uuid.c
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,17 @@
#else
#define THREAD_LOCAL static
#endif
#if defined(__wasi__)
// shim
pid_t getpid(void)
{
return 0;
}
uid_t getuid(void)
{
return 0;
}
#endif

#if defined(__linux__) && defined(__NR_gettid) && defined(HAVE_JRAND48)
#define DO_JRAND_MIX
Expand Down

0 comments on commit 4c41214

Please sign in to comment.