comparison syscalls.c @ 23:2bce4dbf52b8

Use CR/LF to printfs (should probably do the conversion in _write)
author Daniel O'Connor <darius@dons.net.au>
date Sat, 17 Nov 2012 12:15:17 +1030
parents 74e9b3baac1e
children 435c6330896c
comparison
equal deleted inserted replaced
22:198ac9d95770 23:2bce4dbf52b8
26 return -1; 26 return -1;
27 } 27 }
28 28
29 void 29 void
30 _exit(int status) { 30 _exit(int status) {
31 printf("_exit called with parameter %d\n", status); 31 printf("_exit called with parameter %d\r\n", status);
32 __disable_irq();
32 while(1) 33 while(1)
33 ; 34 ;
34 } 35 }
35 36
36 int 37 int
60 heap_end = &_end; 61 heap_end = &_end;
61 } 62 }
62 prev_heap_end = heap_end; 63 prev_heap_end = heap_end;
63 64
64 if (heap_end + incr > get_stack_top()) { 65 if (heap_end + incr > get_stack_top()) {
65 printf("Heap and stack collision\n"); 66 printf("Heap and stack collision\r\n");
66 abort(); 67 abort();
67 } 68 }
68 69
69 heap_end += incr; 70 heap_end += incr;
70 return (caddr_t) prev_heap_end; 71 return (caddr_t) prev_heap_end;