diff --git a/include/zephyr/data/jwt.h b/include/zephyr/data/jwt.h index 8d6121b939498e..d198251f744a5c 100644 --- a/include/zephyr/data/jwt.h +++ b/include/zephyr/data/jwt.h @@ -110,12 +110,6 @@ int jwt_sign(struct jwt_builder *builder, const char *der_key, size_t der_key_len); - -static inline size_t jwt_payload_len(struct jwt_builder *builder) -{ - return (builder->buf - builder->base); -} - #ifdef __cplusplus } #endif diff --git a/tests/subsys/jwt/src/main.c b/tests/subsys/jwt/src/main.c index ab61cd36220263..7ca5ed1e6a8523 100644 --- a/tests/subsys/jwt/src/main.c +++ b/tests/subsys/jwt/src/main.c @@ -50,7 +50,7 @@ ZTEST(jwt_tests, test_jwt) zassert_equal(build.overflowed, false, "Not overflow"); printk("JWT:\n%s\n", buf); - printk("len: %zd\n", jwt_payload_len(&build)); + printk("len: %zd\n", strlen(buf)); } ZTEST_SUITE(jwt_tests, NULL, NULL, NULL, NULL, NULL);