Skip to content

Commit 328f7f9

Browse files
committed
Fix page permissions on upcall trampolines.
1 parent 98a4742 commit 328f7f9

File tree

1 file changed

+1
-1
lines changed
  • substratevm/src/com.oracle.svm.core.foreign/src/com/oracle/svm/core/foreign

1 file changed

+1
-1
lines changed

substratevm/src/com.oracle.svm.core.foreign/src/com/oracle/svm/core/foreign/TrampolineSet.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ private Pointer prepareTrampolines(PinnedObject mhsArray, PinnedObject stubsArra
159159
VMError.guarantee(it.belowOrEqual(end), "Not enough memory was allocated to hold trampolines");
160160
}
161161

162-
VMError.guarantee(VirtualMemoryProvider.get().protect(page, pageSize, VirtualMemoryProvider.Access.EXECUTE) == 0,
162+
VMError.guarantee(VirtualMemoryProvider.get().protect(page, pageSize, VirtualMemoryProvider.Access.READ | VirtualMemoryProvider.Access.EXECUTE) == 0,
163163
"Error when making the trampoline allocation executable");
164164

165165
/*

0 commit comments

Comments
 (0)