logging: Use new cbprintf check for pointers
Cbprintf has new feature where it can distinguish between character pointers used for %p and %s. It is enabled by flag CBPRINTF_PACKAGE_CONVERT_PTR_CHECK. Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
This commit is contained in:
parent
f40c2b9550
commit
b097f5c5f8
1 changed files with 2 additions and 1 deletions
|
@ -52,7 +52,8 @@ void z_impl_z_log_msg_static_create(const void *source,
|
|||
struct log_msg *msg;
|
||||
|
||||
if (inlen > 0) {
|
||||
uint32_t flags = CBPRINTF_PACKAGE_CONVERT_RW_STR;
|
||||
uint32_t flags = CBPRINTF_PACKAGE_CONVERT_RW_STR |
|
||||
CBPRINTF_PACKAGE_CONVERT_PTR_CHECK;
|
||||
uint16_t strl[4];
|
||||
int len;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue