Package: newsbeuter / 2.9-8

04-cache-deletion-with-one-feed.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
Description: Fixes a bug that deleted the cache if there is one feed configured
 This patch also includes a cleanup done later taken from
 https://github.com/akrennmair/newsbeuter/pull/192 upstream commit 931e9ae.
Origin: upstream, https://github.com/akrennmair/newsbeuter/pull/179
Bug: https://github.com/akrennmair/newsbeuter/issues/180

--- a/src/cache.cpp
+++ b/src/cache.cpp
@@ -555,15 +555,11 @@
 		LOG(LOG_DEBUG,"cache::cleanup_cache: cleaning up cache...");
 		std::string list = "(";
 		int rc;
-		unsigned int i = 0;
-		unsigned int feed_size = feeds.size();
 
 		for (auto feed : feeds) {
 			std::string name = prepare_query("'%q'",feed->rssurl().c_str());
 			list.append(name);
-			if (i < feed_size-1) {
-				list.append(", ");
-			}
+			list.append(", ");
 		}
 		list.append("'')");