override _sbrk instead of _sbrk_r and repair merge

This commit is contained in:
Samuel Sadok
2018-03-15 17:39:13 -07:00
parent edf6ffd77a
commit 37db565dad
2 changed files with 3 additions and 1 deletions
+2 -1
View File
@@ -19,6 +19,7 @@
//int _fstat(int file, struct stat *st) {}
//int _isatty(int file) {}extern char _end; // provided by the linker script
extern char _end; // provided by the linker script
extern char _heap_end_max; // provided by the linker script
void* _end_ptr = &_end;
void* _heap_end_max_ptr = &_heap_end_max;
@@ -39,7 +40,7 @@ void* heap_end_ptr = 0;
* @return A pointer to the newly allocated block on success
* or -1 otherwise.
*/
intptr_t _sbrk_r(struct _reent *ignored __attribute__((unused)), size_t size) {
intptr_t _sbrk(size_t size) {
intptr_t ptr;
vTaskSuspendAll();
{
+1
View File
@@ -109,6 +109,7 @@ end
-- TODO: cleaner separation of the platform code and the rest
stm_includes += 'MotorControl'
stm_includes += 'Drivers/DRV8301'
stm_sources += boarddir..'/Src/syscalls.c'
build{
name='stm_platform',
type='objects',