Skip to content

Commit

Permalink
<BugFix> Incorrect pointer de-ref in arch_rseed_capture
Browse files Browse the repository at this point in the history
Issue: #236
  • Loading branch information
akashkollipara committed Jan 4, 2024
1 parent 8fa7b8c commit eab0cc5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/arch/avr/8/common_5x_6/terravisor/arch.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* CYANCORE LICENSE
* Copyrights (C) 2019, Cyancore Team
* Copyrights (C) 2024, Cyancore Team
*
* File Name : arch.c
* Description : This file consists of architecture specific function that
Expand Down Expand Up @@ -149,5 +149,5 @@ void arch_signal_resume(void)
void arch_rseed_capture()
{
extern uintptr_t *_bss_start;
srand(*_bss_start);
srand((size_t)_bss_start);
}
4 changes: 2 additions & 2 deletions src/arch/riscv/32/i/terravisor/arch.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* CYANCORE LICENSE
* Copyrights (C) 2019, Cyancore Team
* Copyrights (C) 2024, Cyancore Team
*
* File Name : arch.c
* Description : This file consists of architecture specific function that
Expand Down Expand Up @@ -170,5 +170,5 @@ _WEAK void arch_unhandled_irq()
void arch_rseed_capture()
{
extern uintptr_t *_bss_start;
srand(*_bss_start);
srand((size_t)_bss_start);
}

0 comments on commit eab0cc5

Please sign in to comment.