1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-11-03 19:37:16 -05:00
profanity/tests/unittests
IsaacM88 d043d53948 Fix duplicate download IDs.
Fixes https://github.com/profanity-im/profanity/issues/1794

Explanation
The problem is the download's identifier. Downloads are given an ID so they can be referenced later when their progress changes. Currently, the download's ID is the download's URL. When you download the same file twice, you have two downloads with the same ID. Download progress updates are shown on the first of both downloads with the same ID.

Solution
Change the download's ID from its URL to a random number. A random ID is generated when get_random_string() is called from cmd_funcs.c. Several other functions are updated to cope with the new ID format.
2023-03-09 15:02:26 -07:00
..
chatlog add chatlog unittest 2022-06-28 20:46:35 +02:00
config add chatlog unittest 2022-06-28 20:46:35 +02:00
database Update copyright year 2023-01-10 10:37:25 +01:00
log minor changes 2023-01-18 20:02:46 +01:00
omemo Use our omemo sid/fingerprint in qr code 2022-05-31 15:44:44 +02:00
otr Apply coding style 2020-07-07 14:18:57 +02:00
pgp Split ox functions from gpg.c to ox.c 2022-06-29 09:17:15 +02:00
tools Fix duplicate download IDs. 2023-03-09 15:02:26 -07:00
ui Fix duplicate download IDs. 2023-03-09 15:02:26 -07:00
xmpp add now option to /reconnect command 2023-01-18 20:02:46 +01:00
helpers.c use g_mkdir_with_parents() instead of home-baked solution 2022-03-14 13:17:46 +01:00
helpers.h Fix: files missing final ending newline 2021-08-26 00:28:49 +00:00
test_autocomplete.c Apply coding style 2020-07-07 14:18:57 +02:00
test_autocomplete.h Apply coding style 2020-07-07 14:18:57 +02:00
test_callbacks.c auto-format 2022-02-01 15:01:28 +01:00
test_callbacks.h Apply coding style 2020-07-07 14:18:57 +02:00
test_chat_session.c Apply coding style 2020-07-07 14:18:57 +02:00
test_chat_session.h Fix: files missing final ending newline 2021-08-26 00:28:49 +00:00
test_cmd_account.c let account_new() take ownership of passed values 2023-01-18 20:02:46 +01:00
test_cmd_account.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_alias.c Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_alias.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_bookmark.c Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_bookmark.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_connect.c let account_new() take ownership of passed values 2023-01-18 20:02:46 +01:00
test_cmd_connect.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_disconnect.c Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_disconnect.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_join.c let account_new() take ownership of passed values 2023-01-18 20:02:46 +01:00
test_cmd_join.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_otr.c let account_new() take ownership of passed values 2023-01-18 20:02:46 +01:00
test_cmd_otr.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_pgp.c Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_pgp.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_presence.c Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_presence.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_rooms.c let account_new() take ownership of passed values 2023-01-18 20:02:46 +01:00
test_cmd_rooms.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_roster.c Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_roster.h Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_sub.c Apply coding style 2020-07-07 14:18:57 +02:00
test_cmd_sub.h Apply coding style 2020-07-07 14:18:57 +02:00
test_common.c Add tests for format_call_external_argv 2020-12-07 16:16:15 +01:00
test_common.h Add tests for format_call_external_argv 2020-12-07 16:16:15 +01:00
test_contact.c Apply coding style 2020-07-07 14:18:57 +02:00
test_contact.h Apply coding style 2020-07-07 14:18:57 +02:00
test_form.c Apply coding style 2020-07-07 14:18:57 +02:00
test_form.h Apply coding style 2020-07-07 14:18:57 +02:00
test_jid.c Apply coding style 2020-07-07 14:18:57 +02:00
test_jid.h Apply coding style 2020-07-07 14:18:57 +02:00
test_keyhandlers.c Fix: files missing final ending newline 2021-08-26 00:28:49 +00:00
test_keyhandlers.h Fix: files missing final ending newline 2021-08-26 00:28:49 +00:00
test_muc.c Apply coding style 2020-07-07 14:18:57 +02:00
test_muc.h Apply coding style 2020-07-07 14:18:57 +02:00
test_parser.c Apply coding style 2020-07-07 14:18:57 +02:00
test_parser.h Apply coding style 2020-07-07 14:18:57 +02:00
test_plugins_disco.c Apply coding style 2020-07-07 14:18:57 +02:00
test_plugins_disco.h Apply coding style 2020-07-07 14:18:57 +02:00
test_preferences.c Fix preferences tests 2022-04-08 10:14:29 +02:00
test_preferences.h Apply coding style 2020-07-07 14:18:57 +02:00
test_roster_list.c Add unit tests for roster_get_display_name 2021-06-30 18:58:07 -04:00
test_roster_list.h Add unit tests for roster_get_display_name 2021-06-30 18:58:07 -04:00
test_server_events.c Apply coding style 2020-07-07 14:18:57 +02:00
test_server_events.h Apply coding style 2020-07-07 14:18:57 +02:00
unittests.c Add unit tests for roster_get_display_name 2021-06-30 18:58:07 -04:00