Skip to content

Commit

Permalink
COMPAT: Set Prolog flag gc_thread to false
Browse files Browse the repository at this point in the history
SWI-Prolog used to disable the garbage collection thread on `--no-signals`.
This was for JPL and is removed in version 9.1.18.   It is unclear why using
a separate GC thread causes the `prolog_in_java` test to hang.

This patch sets the GC thread explicitly.
  • Loading branch information
JanWielemaker committed Oct 16, 2023
1 parent fb08b41 commit 40fdc82
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/main/c/jpl.c
Original file line number Diff line number Diff line change
Expand Up @@ -3133,6 +3133,7 @@ jpl_do_pvm_init(JNIEnv *env)
{ msg = "jpl_do_pvm_init(): PL_initialise() failed";
goto err;
}
PL_set_prolog_flag("gc_thread", PL_BOOL, FALSE);
/* *don't* free argv (must exist for lifetime of Prolog VM) */

return jpl_post_pvm_init(env, argc, argv); /* TRUE, FALSE or exception */
Expand Down

0 comments on commit 40fdc82

Please sign in to comment.