From ec391decd94ac9f6c6133c24a41c8afb2c01623f Mon Sep 17 00:00:00 2001 From: Felix Herrmann Date: Fri, 10 Jan 2020 16:10:33 +0100 Subject: fix clang warnings about GNU stuff Signed-off-by: Felix Herrmann Signed-off-by: KHANH LUONG HONG DUY --- src/shared/dlt_offline_trace.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/shared') diff --git a/src/shared/dlt_offline_trace.c b/src/shared/dlt_offline_trace.c index 303d6b3..060b97f 100644 --- a/src/shared/dlt_offline_trace.c +++ b/src/shared/dlt_offline_trace.c @@ -195,7 +195,7 @@ DltReturnValue dlt_offline_trace_create_new_file(DltOfflineTrace *trace) DLT_OFFLINETRACE_FILENAME_TIMESTAMP_DELI, timestamp, DLT_OFFLINETRACE_FILENAME_EXT); - if ((ret < 0) || (ret >= (int)sizeof(trace->filename))) { + if ((ret < 0) || ((size_t)ret >= (int)sizeof(trace->filename))) { printf("dlt_offlinetrace filename cannot be concatenated\n"); return DLT_RETURN_ERROR; } @@ -203,7 +203,7 @@ DltReturnValue dlt_offline_trace_create_new_file(DltOfflineTrace *trace) ret = snprintf(file_path, sizeof(file_path), "%s/%s", trace->directory, trace->filename); - if ((ret < 0) || (ret >= (int)sizeof(file_path))) { + if ((ret < 0) || ((size_t)ret >= (int)sizeof(file_path))) { printf("dlt_offlinetrace file path cannot be concatenated\n"); return DLT_RETURN_ERROR; } -- cgit v1.2.1