Lines Matching refs:assert_msg
48 #define assert_msg(x, msg) do { if (unlikely(!(x))) { fprintf(stderr, "Assert not met in %s:%d: %s\… macro
163 assert_msg(count > 0, "Usage error: attempted to write invalid number of bytes to socket"); in write_or_fail()
196 assert_msg(count > 0, "Usage error: attempted to read invalid number of bytes from socket"); in read_or_fail()
224 assert_msg(response == SUCCESS_HANDSHAKE, "API command version mismatch"); in perform_handshake()
342 assert_msg(callbacks_count < MAX_CALLBACK_COUNT, "Cannot register any more callbacks"); in register_callback()
358 …assert_msg(response->ed < callbacks_count, "Tried to invoke callback for an invalid event descript… in invoke_callback()
359 …assert_msg(response->size == sizeof(renode_gpio_event_data_t), ERRMSG_UNEXPECTED_RESPONSE_PAYLOAD_… in invoke_callback()
365 assert_msg(false, "Tried to invoke callback for an invalid command"); in invoke_callback()
517 assert_msg(data_size == 4, "received unexpected number of bytes"); in renode_get_machine()
519 assert_msg(data[0] >= 0, "received invalid machine descriptor"); in renode_get_machine()
541 assert_msg(data_size == 4, "received unexpected number of bytes"); in renode_get_instance_descriptor()
545 assert_msg(*instance_descriptor >= 0, "received invalid instance descriptor"); in renode_get_instance_descriptor()
627 assert_msg(response_size == sizeof(*current_time), ERRMSG_UNEXPECTED_RESPONSE_PAYLOAD_SIZE); in renode_get_current_time()
682 assert_msg(response_size == sizeof(*count), ERRMSG_UNEXPECTED_RESPONSE_PAYLOAD_SIZE); in renode_get_adc_channel_count()
703 assert_msg(response_size == sizeof(*value), ERRMSG_UNEXPECTED_RESPONSE_PAYLOAD_SIZE); in renode_get_adc_channel_value()
725 assert_msg(response_size == 0, ERRMSG_UNEXPECTED_RESPONSE_PAYLOAD_SIZE); in renode_set_adc_channel_value()
776 assert_msg(response_size == sizeof(value), ERRMSG_UNEXPECTED_RESPONSE_PAYLOAD_SIZE); in renode_get_gpio_state()
798 assert_msg(response_size == 0, ERRMSG_UNEXPECTED_RESPONSE_PAYLOAD_SIZE); in renode_set_gpio_state()
831 assert_msg(response_size == 0, ERRMSG_UNEXPECTED_RESPONSE_PAYLOAD_SIZE); in renode_register_gpio_state_change_callback()