diff --git a/other/event_tooling/generate_event_c.cpp b/other/event_tooling/generate_event_c.cpp index 12da6a34d2c..4f0702bb41d 100644 --- a/other/event_tooling/generate_event_c.cpp +++ b/other/event_tooling/generate_event_c.cpp @@ -258,7 +258,7 @@ void generate_event_impl(const std::string& event_name, std::vector e }, [&](const EventTypeByteRange& t) { //f << "non_null()\n"; // TODO: is this missing in the original? - f << "size_t tox_event_" << event_name_l << "_get_" << t.name_length; + f << "size_t tox_event_" << event_name_l << "_get_" << t.name_length_cb; f << "(const Tox_Event_" << event_name << " *" << event_name_l << ")\n"; f << "{\n assert(" << event_name_l << " != nullptr);\n"; f << " return " << event_name_l << "->" << t.name_length << ";\n}\n"; diff --git a/toxcore/events/group_custom_packet.c b/toxcore/events/group_custom_packet.c index 395c4eeb969..6b9c845ff54 100644 --- a/toxcore/events/group_custom_packet.c +++ b/toxcore/events/group_custom_packet.c @@ -91,7 +91,7 @@ static bool tox_event_group_custom_packet_set_data(Tox_Event_Group_Custom_Packet group_custom_packet->data_length = data_length; return true; } -size_t tox_event_group_custom_packet_get_data_length(const Tox_Event_Group_Custom_Packet *group_custom_packet) +size_t tox_event_group_custom_packet_get_length(const Tox_Event_Group_Custom_Packet *group_custom_packet) { assert(group_custom_packet != nullptr); return group_custom_packet->data_length; diff --git a/toxcore/events/group_custom_private_packet.c b/toxcore/events/group_custom_private_packet.c index bbae86589ed..86beeca8f19 100644 --- a/toxcore/events/group_custom_private_packet.c +++ b/toxcore/events/group_custom_private_packet.c @@ -91,7 +91,7 @@ static bool tox_event_group_custom_private_packet_set_data(Tox_Event_Group_Custo group_custom_private_packet->data_length = data_length; return true; } -size_t tox_event_group_custom_private_packet_get_data_length(const Tox_Event_Group_Custom_Private_Packet *group_custom_private_packet) +size_t tox_event_group_custom_private_packet_get_length(const Tox_Event_Group_Custom_Private_Packet *group_custom_private_packet) { assert(group_custom_private_packet != nullptr); return group_custom_private_packet->data_length; diff --git a/toxcore/events/group_invite.c b/toxcore/events/group_invite.c index dddc1f48fbf..e48974d1d5e 100644 --- a/toxcore/events/group_invite.c +++ b/toxcore/events/group_invite.c @@ -80,7 +80,7 @@ static bool tox_event_group_invite_set_invite_data(Tox_Event_Group_Invite *group group_invite->invite_data_length = invite_data_length; return true; } -size_t tox_event_group_invite_get_invite_data_length(const Tox_Event_Group_Invite *group_invite) +size_t tox_event_group_invite_get_length(const Tox_Event_Group_Invite *group_invite) { assert(group_invite != nullptr); return group_invite->invite_data_length; diff --git a/toxcore/events/group_message.c b/toxcore/events/group_message.c index ab4d23d4192..9236e4628a3 100644 --- a/toxcore/events/group_message.c +++ b/toxcore/events/group_message.c @@ -106,7 +106,7 @@ static bool tox_event_group_message_set_message(Tox_Event_Group_Message *group_m group_message->message_length = message_length; return true; } -size_t tox_event_group_message_get_message_length(const Tox_Event_Group_Message *group_message) +size_t tox_event_group_message_get_length(const Tox_Event_Group_Message *group_message) { assert(group_message != nullptr); return group_message->message_length; diff --git a/toxcore/events/group_password.c b/toxcore/events/group_password.c index 45b2650bd27..5a7284c6496 100644 --- a/toxcore/events/group_password.c +++ b/toxcore/events/group_password.c @@ -77,7 +77,7 @@ static bool tox_event_group_password_set_password(Tox_Event_Group_Password *grou group_password->password_length = password_length; return true; } -size_t tox_event_group_password_get_password_length(const Tox_Event_Group_Password *group_password) +size_t tox_event_group_password_get_length(const Tox_Event_Group_Password *group_password) { assert(group_password != nullptr); return group_password->password_length; diff --git a/toxcore/events/group_peer_name.c b/toxcore/events/group_peer_name.c index b5eb859d35e..c042c113970 100644 --- a/toxcore/events/group_peer_name.c +++ b/toxcore/events/group_peer_name.c @@ -91,7 +91,7 @@ static bool tox_event_group_peer_name_set_name(Tox_Event_Group_Peer_Name *group_ group_peer_name->name_length = name_length; return true; } -size_t tox_event_group_peer_name_get_name_length(const Tox_Event_Group_Peer_Name *group_peer_name) +size_t tox_event_group_peer_name_get_length(const Tox_Event_Group_Peer_Name *group_peer_name) { assert(group_peer_name != nullptr); return group_peer_name->name_length; diff --git a/toxcore/events/group_private_message.c b/toxcore/events/group_private_message.c index f5af54a4fcf..9dc7ac9bc6f 100644 --- a/toxcore/events/group_private_message.c +++ b/toxcore/events/group_private_message.c @@ -105,7 +105,7 @@ static bool tox_event_group_private_message_set_message(Tox_Event_Group_Private_ group_private_message->message_length = message_length; return true; } -size_t tox_event_group_private_message_get_message_length(const Tox_Event_Group_Private_Message *group_private_message) +size_t tox_event_group_private_message_get_length(const Tox_Event_Group_Private_Message *group_private_message) { assert(group_private_message != nullptr); return group_private_message->message_length; diff --git a/toxcore/events/group_topic.c b/toxcore/events/group_topic.c index c9d815231b7..fca8b67818e 100644 --- a/toxcore/events/group_topic.c +++ b/toxcore/events/group_topic.c @@ -91,7 +91,7 @@ static bool tox_event_group_topic_set_topic(Tox_Event_Group_Topic *group_topic, group_topic->topic_length = topic_length; return true; } -size_t tox_event_group_topic_get_topic_length(const Tox_Event_Group_Topic *group_topic) +size_t tox_event_group_topic_get_length(const Tox_Event_Group_Topic *group_topic) { assert(group_topic != nullptr); return group_topic->topic_length;