Skip to content

Commit 89c1bef

Browse files
authored
Merge pull request #1916 from c1728p9/fix_gcc
Fix GCC malloc lock
2 parents 35cacf6 + 8c2e352 commit 89c1bef

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

hal/common/retarget.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -646,22 +646,22 @@ extern "C" WEAK void __rtos_malloc_unlock( struct _reent *_r ) {}
646646
extern "C" WEAK void __rtos_env_lock( struct _reent *_r ) {}
647647
extern "C" WEAK void __rtos_env_unlock( struct _reent *_r ) {}
648648

649-
void __malloc_lock( struct _reent *_r )
649+
extern "C" void __malloc_lock( struct _reent *_r )
650650
{
651651
__rtos_malloc_lock(_r);
652652
}
653653

654-
void __malloc_unlock( struct _reent *_r )
654+
extern "C" void __malloc_unlock( struct _reent *_r )
655655
{
656656
__rtos_malloc_unlock(_r);
657657
}
658658

659-
void __env_lock( struct _reent *_r )
659+
extern "C" void __env_lock( struct _reent *_r )
660660
{
661661
__rtos_env_lock(_r);
662662
}
663663

664-
void __env_unlock( struct _reent *_r )
664+
extern "C" void __env_unlock( struct _reent *_r )
665665
{
666666
__rtos_env_unlock(_r);
667667
}

0 commit comments

Comments
 (0)