From 56e1095287ee1fa354232abb3e6674328cd21eb0 Mon Sep 17 00:00:00 2001 From: Fufu Fang Date: Wed, 4 Sep 2019 17:41:34 +0100 Subject: [PATCH] tidying stuff up --- src/cache.h | 2 +- src/network.c | 9 ++++----- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/src/cache.h b/src/cache.h index e4ce33f..e30c227 100644 --- a/src/cache.h +++ b/src/cache.h @@ -89,7 +89,7 @@ extern int MAX_SEGBC; * If these directories do not exist, they will be created. * \note Called by parse_arg_list(), verified to be working */ -void CacheSystem_init(const char *path, int path_supplied); +void CacheSystem_init(const char *path, int url_supplied); /** * \brief Create directories under the cache directory structure, if they do diff --git a/src/network.c b/src/network.c index 1e98295..d316705 100644 --- a/src/network.c +++ b/src/network.c @@ -26,7 +26,6 @@ static pthread_mutex_t transfer_lock; static pthread_mutex_t *crypto_lockarray; /** \brief mutex for curl share interface itself */ static pthread_mutex_t curl_lock; -/** \brief network configuration */ /* -------------------- Functions -------------------------- */ #pragma GCC diagnostic push @@ -37,9 +36,9 @@ static pthread_mutex_t curl_lock; */ static void crypto_lock_callback(int mode, int type, char *file, int line) { - (void)file; - (void)line; - if(mode & CRYPTO_LOCK) { + (void) file; + (void) line; + if (mode & CRYPTO_LOCK) { PTHREAD_MUTEX_LOCK(&(crypto_lockarray[type])); } else { PTHREAD_MUTEX_UNLOCK(&(crypto_lockarray[type])); @@ -133,7 +132,7 @@ static void curl_process_msgs(CURLMsg *curl_msg, int n_running_curl, } if (!curl_msg->data.result) { - /* Transfer successful, query the file size */ + /* Transfer successful, set the file size */ if (transfer->type == FILESTAT) { Link_set_file_stat(transfer->link, curl); }