aboutsummaryrefslogtreecommitdiff
path: root/src/AsyncImageLoader.cpp
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2021-07-17 09:43:20 +0200
committerdec05eba <dec05eba@protonmail.com>2021-07-17 09:43:20 +0200
commite671784144174c4fceaa6df3737ba9b4de4a6c63 (patch)
treea3ad7d12959b92f5be9430c961d86a9c131d7036 /src/AsyncImageLoader.cpp
parentb09d1e70661226697e2441c18ea6ff59c387fb93 (diff)
Youtube: remove dependency on youtube-dl for downloads (also fixes downloads of age restricted videos)
Diffstat (limited to 'src/AsyncImageLoader.cpp')
-rw-r--r--src/AsyncImageLoader.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/AsyncImageLoader.cpp b/src/AsyncImageLoader.cpp
index 3e00459..ccf9f42 100644
--- a/src/AsyncImageLoader.cpp
+++ b/src/AsyncImageLoader.cpp
@@ -21,11 +21,7 @@
namespace QuickMedia {
static bool webp_to_png(const Path &thumbnail_path, const Path &destination_path) {
const char *args[] = { "ffmpeg", "-y", "-v", "quiet", "-i", thumbnail_path.data.c_str(), "--", destination_path.data.c_str(), nullptr};
- int res = exec_program(args, nullptr, nullptr);
- if(res != 0)
- return false;
-
- return true;
+ return exec_program(args, nullptr, nullptr) == 0;
}
bool create_thumbnail(const Path &thumbnail_path, const Path &thumbnail_path_resized, sf::Vector2i resize_target_size, ContentType content_type) {