kernel: tests: Increased TX/RX buf size in pipe test

Increased TX/RX buffer size by one in pipe test to prevent buffer
overrun.

Some test will transfer one byte more then the number of bytes
supported by the pipe, in case the buffer size is the same as the
size of the pipe this will result in a buffer overrun.
Tools such as address sanitizer would detect this overrun and fail the
test.

Signed-off-by: Jan Van Winkel <jan.van_winkel@dxplore.eu>
This commit is contained in:
Jan Van Winkel 2019-08-24 22:12:37 +02:00 committed by Anas Nashif
parent 13433fcc4b
commit 7c07093f66
1 changed files with 2 additions and 2 deletions

View File

@ -19,8 +19,8 @@ K_SEM_DEFINE(sync_sem, 0, 1);
K_SEM_DEFINE(multiple_send_sem, 0, 1);
ZTEST_BMEM u8_t tx_buffer[PIPE_SIZE];
ZTEST_BMEM u8_t rx_buffer[PIPE_SIZE];
ZTEST_BMEM u8_t tx_buffer[PIPE_SIZE + 1];
ZTEST_BMEM u8_t rx_buffer[PIPE_SIZE + 1];
#define TOTAL_ELEMENTS (sizeof(single_elements) / sizeof(struct pipe_sequence))
#define TOTAL_WAIT_ELEMENTS (sizeof(wait_elements) / \