From 9c1c0fbcd8c12f04df4064b3b45d30f22fb3f721 Mon Sep 17 00:00:00 2001 From: Saya Sugiura Date: Thu, 13 Dec 2018 16:27:07 +0900 Subject: libdlt: Add error handling Error handling was added in case it failed to send to daemon. Signed-off-by: S. Hameed Signed-off-by: Saya Sugiura --- include/dlt/dlt_common.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include') diff --git a/include/dlt/dlt_common.h b/include/dlt/dlt_common.h index fa68997..3db3a27 100644 --- a/include/dlt/dlt_common.h +++ b/include/dlt/dlt_common.h @@ -1274,6 +1274,13 @@ extern "C" */ DltReturnValue dlt_buffer_free_dynamic(DltBuffer *buf); + /** + * Check if message fits into buffer. + * @param buf Pointer to buffer structure + * @return DLT_RETURN_OK if enough space, DLT_RETURN_ERROR otherwise + */ + DltReturnValue dlt_buffer_check_size(DltBuffer *buf, int needed); + /** * Write one entry to ringbuffer * @param buf Pointer to ringbuffer structure -- cgit v1.2.1