Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIvan Arishchenko <36693675+iarischenko@users.noreply.github.com>2018-05-30 14:48:58 +0300
committerJan Kotas <jkotas@microsoft.com>2018-05-30 14:48:58 +0300
commit383344243e5db8be57e8e375d2f58813d8eadd28 (patch)
tree6044296270d5d0626abc8f967ce9b41c2844ec38 /src/Native
parent42debf49f780cb8e740de31d0ca81bbf435a2eba (diff)
Fix: call memory allocation instead of return (#5866)
The code EPILOG_POP "{r4,pc}" arm/AllocFast.S:472 RhpNewFastMisalign() returns from the RhpNewFastMisalign function without memory allocation, the input parameter (EEType pointer) is returned as result of memory allocation. It leads to using the EEType as object and application crashed with SIGSEGV.
Diffstat (limited to 'src/Native')
-rw-r--r--src/Native/Runtime/arm/AllocFast.S2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Native/Runtime/arm/AllocFast.S b/src/Native/Runtime/arm/AllocFast.S
index e4dd26643..ec9260855 100644
--- a/src/Native/Runtime/arm/AllocFast.S
+++ b/src/Native/Runtime/arm/AllocFast.S
@@ -469,7 +469,7 @@ LOCAL_LABEL(BoxAlloc8Failed):
// finalization.
mov r0, r4 // restore EEType
mov r1, #(GC_ALLOC_ALIGN8 | GC_ALLOC_ALIGN8_BIAS)
- EPILOG_POP "{r4,pc}"
+ EPILOG_POP "{r4,lr}"
b C_FUNC(RhpNewObject)
LEAF_END RhpNewFastMisalign, _TEXT