Skip to content

Commit 7a8946f

Browse files
committed
Replacing getchar with RawSerial getc in greentea-client.
This change prevents the standard library from allocating a large buffer on the heap. On GCC_ARM, this is a saving of 1K. On ARM, this is a saving of 64 bytes.
1 parent 4198222 commit 7a8946f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

features/frameworks/greentea-client/source/test_env.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -533,7 +533,7 @@ enum Token {
533533
*
534534
*/
535535
static int _get_char() {
536-
return getchar();
536+
return greentea_serial->getc();
537537
}
538538

539539
/**

0 commit comments

Comments
 (0)