"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "tests/libntp/recvbuff.c" between
ntp-4.2.8p14.tar.gz and ntp-4.2.8p15.tar.gz

About: NTP is the the Official Reference Implementation of the Network Time Protocol (NTP) that synchronize the clocks of computers over a network.

recvbuff.c  (ntp-4.2.8p14):recvbuff.c  (ntp-4.2.8p15)
skipping to change at line 32 skipping to change at line 32
test_Initialization(void) { test_Initialization(void) {
TEST_ASSERT_EQUAL_UINT(RECV_INIT, free_recvbuffs()); TEST_ASSERT_EQUAL_UINT(RECV_INIT, free_recvbuffs());
TEST_ASSERT_EQUAL_UINT(0, full_recvbuffs()); TEST_ASSERT_EQUAL_UINT(0, full_recvbuffs());
TEST_ASSERT_FALSE(has_full_recv_buffer()); TEST_ASSERT_FALSE(has_full_recv_buffer());
TEST_ASSERT_NULL(get_full_recv_buffer()); TEST_ASSERT_NULL(get_full_recv_buffer());
} }
void void
test_GetAndFree(void) { test_GetAndFree(void) {
u_long initial = free_recvbuffs(); u_long initial = free_recvbuffs();
recvbuf_t* buf = get_free_recv_buffer(); recvbuf_t* buf = get_free_recv_buffer(TRUE);
TEST_ASSERT_EQUAL_UINT(initial-1, free_recvbuffs()); TEST_ASSERT_EQUAL_UINT(initial-1, free_recvbuffs());
freerecvbuf(buf); freerecvbuf(buf);
TEST_ASSERT_EQUAL_UINT(initial, free_recvbuffs()); TEST_ASSERT_EQUAL_UINT(initial, free_recvbuffs());
} }
void void
test_GetAndFill(void) { test_GetAndFill(void) {
// int initial = free_recvbuffs(); // int initial = free_recvbuffs();
recvbuf_t* buf = get_free_recv_buffer(); recvbuf_t* buf = get_free_recv_buffer(TRUE);
add_full_recv_buffer(buf); add_full_recv_buffer(buf);
TEST_ASSERT_EQUAL_UINT(1, full_recvbuffs()); TEST_ASSERT_EQUAL_UINT(1, full_recvbuffs());
TEST_ASSERT_TRUE(has_full_recv_buffer()); TEST_ASSERT_TRUE(has_full_recv_buffer());
TEST_ASSERT_EQUAL_PTR(buf, get_full_recv_buffer()); TEST_ASSERT_EQUAL_PTR(buf, get_full_recv_buffer());
} }
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)