You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by GitBox <gi...@apache.org> on 2018/10/04 08:40:47 UTC

[GitHub] rymanluk commented on a change in pull request #1399: RTT console fixes

rymanluk commented on a change in pull request #1399: RTT console fixes
URL: https://github.com/apache/mynewt-core/pull/1399#discussion_r222582892
 
 

 ##########
 File path: sys/console/full/src/rtt_console.c
 ##########
 @@ -35,20 +35,25 @@ static const char CR = '\r';
 int
 console_out(int character)
 {
+    os_sr_t sr;
     char c = (char)character;
 
     if (g_silence_console) {
         return c;
     }
 
+    OS_ENTER_CRITICAL(sr);
+
     if ('\n' == c) {
-        SEGGER_RTT_WriteWithOverwriteNoLock(0, &CR, 1);
+        SEGGER_RTT_WriteNoLock(0, &c, 1);
 
 Review comment:
   &CR should be there instead of &c

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services