From d319ebf4d2d449d70befae0eebbdd82c19c5315f Mon Sep 17 00:00:00 2001 From: Lutz Helwing Date: Fri, 19 Feb 2016 14:22:23 +0100 Subject: Truncate of string or raw block, if length exceeds maximum message length Previously if messages containing strings or raw data were exceeding the maximum message size (DLT_USER_BUF_MAX_SIZE, currently set to 1390) they were discarded completely. This behaviour is changed so that too large data is truncated and sent anyway. Commented out part of unit test for dlt_log_raw abnormal where negative values for unsigned length were passed. Change-Id: I4f6bf152e7125924717c941ad7ebb8fd79787715 Signed-off-by: Lutz Helwing --- tests/gtest_dlt_user.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/gtest_dlt_user.cpp b/tests/gtest_dlt_user.cpp index abd0160..c7d8008 100644 --- a/tests/gtest_dlt_user.cpp +++ b/tests/gtest_dlt_user.cpp @@ -2199,8 +2199,8 @@ TEST(t_dlt_log_raw, abnormal) // TODO: EXPECT_GE(DLT_RETURN_ERROR,dlt_log_raw(&context, DLT_LOG_DEFAULT, data, 0)); // negative length - EXPECT_GE(DLT_RETURN_ERROR,dlt_log_raw(&context, DLT_LOG_DEFAULT, data, -1)); - EXPECT_GE(DLT_RETURN_ERROR,dlt_log_raw(&context, DLT_LOG_DEFAULT, data, -100)); +// EXPECT_GE(DLT_RETURN_ERROR,dlt_log_raw(&context, DLT_LOG_DEFAULT, data, -1)); +// EXPECT_GE(DLT_RETURN_ERROR,dlt_log_raw(&context, DLT_LOG_DEFAULT, data, -100)); EXPECT_LE(DLT_RETURN_OK,dlt_unregister_context(&context)); EXPECT_LE(DLT_RETURN_OK,dlt_unregister_app()); -- cgit v1.2.1