manish-sudo commented on a change in pull request #2011: Change Reboot log from 
text to CBOR encoded.
URL: https://github.com/apache/mynewt-core/pull/2011#discussion_r329174070
 
 

 ##########
 File path: sys/reboot/src/log_reboot.c
 ##########
 @@ -220,8 +220,16 @@ log_reboot_write(const struct log_reboot_info *info)
 
     if (info->file != NULL) {
         cbor_encode_text_stringz(&map, "die");
+        off  = 0;
+
+        /* If die filename is longer than 1/3 of total allocated
+         * buffer, then trim the filename from left. */
+        if (strlen(info->file) > (sizeof(buf) / 3))
+        {
 
 Review comment:
   ACK

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


With regards,
Apache Git Services

Reply via email to