aboutsummaryrefslogtreecommitdiff
path: root/src/html.c
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2020-09-27 02:56:13 +0200
committerdec05eba <dec05eba@protonmail.com>2020-09-27 03:29:34 +0200
commita0707a1cf4583f7f00a6fbce2f50fecd09ca7be0 (patch)
tree88bbe0668f1326087a991fc10af9ff5295936ac1 /src/html.c
parent836eda9a772ae91a76adffaadfe098bcc82d4d3d (diff)
Fix multiple items using the same timestamp if updated at the same time
They should use their download finished time instead
Diffstat (limited to 'src/html.c')
-rw-r--r--src/html.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/html.c b/src/html.c
index 6442188..b7abbdf 100644
--- a/src/html.c
+++ b/src/html.c
@@ -379,6 +379,8 @@ static int download_html_items_in_reverse(const char *plugin_filepath, Buffer *d
break;
added_download_items[download_item_index] = download_items_it;
+ // TODO: What if the download is so fast two items have the same timestamp? Maybe substract by MAX_UPDATE_ITEMS and then add 1 each loop,
+ // or use milliseconds/microseconds timestamps?
timestamps[download_item_index] = time(NULL);
++download_item_index;
}