Skip to content

Commit 8af39ce

Browse files
committed
Auto merge of #26321 - srwalter:remove-i386-textrel, r=alexcrichton
This prevents a relocation in the text section. Text relocations are incompatible with hardened kernels. #5714
2 parents 37cc79f + 85be7c5 commit 8af39ce

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

Diff for: src/rt/arch/i386/morestack.S

+2-3
Original file line numberDiff line numberDiff line change
@@ -75,15 +75,14 @@
7575
#else
7676
#if defined(__linux__) || defined(__FreeBSD__)
7777
#define MORESTACK __morestack
78-
#define EXHAUSTED rust_stack_exhausted
78+
#define EXHAUSTED rust_stack_exhausted@plt
7979
#else
8080
#define MORESTACK ___morestack
8181
#define EXHAUSTED _rust_stack_exhausted
8282
#endif
8383
#endif
8484

8585
.globl MORESTACK
86-
.globl EXHAUSTED
8786

8887
// FIXME: What about __WIN32__?
8988
#if defined(__linux__) || defined(__FreeBSD__)
@@ -138,7 +137,7 @@ MORESTACK:
138137

139138
// re-align the stack
140139
subl $12,%esp
141-
calll EXHAUSTED
140+
call EXHAUSTED
142141
// the exhaustion function guarantees that it can't return
143142

144143
.cfi_endproc

0 commit comments

Comments
 (0)