diff options
| author | Eugen Wissner <belka@caraus.de> | 2026-05-20 17:53:57 +0200 |
|---|---|---|
| committer | Eugen Wissner <belka@caraus.de> | 2026-05-20 17:53:57 +0200 |
| commit | 76985de795f33f71684635ad5f14dc84aefea26e (patch) | |
| tree | e8aed126b84b4ba3a76cf26fb9720c0f83eac594 /backend/utils.cpp | |
| parent | c04278ff84c2c4d9c54bbd43c1542e4eace40419 (diff) | |
| download | katja-76985de795f33f71684635ad5f14dc84aefea26e.tar.gz | |
Fix the backend test
Diffstat (limited to 'backend/utils.cpp')
| -rw-r--r-- | backend/utils.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/backend/utils.cpp b/backend/utils.cpp index 086fa42..19d0b39 100644 --- a/backend/utils.cpp +++ b/backend/utils.cpp @@ -52,9 +52,9 @@ struct JobData * * Returns: CURLE_OK (zero) on success, non-zero otherwise. **/ -CURLcode get_file(CURL **curl, char *source_url, char *dest) +CURLcode get_file(CURL **curl, const char *source_url, const char *dest) { - char *dest_dir_name; + const char *dest_dir_name; FILE *fout = nullptr; CURLcode ret; glong response_code; @@ -85,7 +85,7 @@ CURLcode get_file(CURL **curl, char *source_url, char *dest) { dest_dir_name = dest; dest = g_strconcat(dest_dir_name, g_strrstr(source_url, "/"), nullptr); - g_free(dest_dir_name); + g_free(const_cast<char *>(dest_dir_name)); } if ((fout = fopen(dest, "ab")) == nullptr) { |
