mirror of
https://github.com/transmission/transmission
synced 2025-02-20 21:26:53 +00:00
#3833 'freespace' -- fix memset error.
This commit is contained in:
parent
8f9c502dfd
commit
9e86a38345
2 changed files with 5 additions and 8 deletions
|
@ -590,8 +590,6 @@ tr_sessionInit (const char * tag,
|
|||
session->cache = tr_cacheNew (1024*1024*2);
|
||||
session->tag = tr_strdup (tag);
|
||||
session->magicNumber = SESSION_MAGIC_NUMBER;
|
||||
session->downloadDirBlkDev = tr_malloc (TR_PATH_MAX + 1);
|
||||
session->downloadDirFsType = tr_malloc (TR_PATH_MAX + 1);
|
||||
tr_bandwidthConstruct (&session->bandwidth, session, NULL);
|
||||
tr_peerIdInit (session->peer_id);
|
||||
tr_variantInitList (&session->removedTorrents, 0);
|
||||
|
@ -969,12 +967,13 @@ tr_sessionGetDownloadDir (const tr_session * session)
|
|||
}
|
||||
|
||||
int64_t
|
||||
tr_sessionGetDownloadDirFreeSpace (const tr_session * session)
|
||||
tr_sessionGetDownloadDirFreeSpace (tr_session * session)
|
||||
{
|
||||
assert (tr_isSession (session));
|
||||
|
||||
return tr_getFreeSpace (session->downloadDir, session->downloadDirBlkDev,
|
||||
session->downloadDirFsType);
|
||||
return tr_getFreeSpace (session->downloadDir,
|
||||
session->downloadDirBlkDev,
|
||||
session->downloadDirFsType);
|
||||
}
|
||||
|
||||
/***
|
||||
|
@ -1884,8 +1883,6 @@ tr_sessionClose (tr_session * session)
|
|||
tr_free (session->resumeDir);
|
||||
tr_free (session->torrentDir);
|
||||
tr_free (session->downloadDir);
|
||||
tr_free (session->downloadDirBlkDev);
|
||||
tr_free (session->downloadDirFsType);
|
||||
tr_free (session->incompleteDir);
|
||||
tr_free (session->blocklist_url);
|
||||
tr_free (session->peer_congestion_algorithm);
|
||||
|
|
|
@ -294,7 +294,7 @@ const char * tr_sessionGetDownloadDir (const tr_session * session);
|
|||
* @brief Get available disk space (in bytes) for the default download folder.
|
||||
* @return zero or positive integer on success, -1 in case of error.
|
||||
*/
|
||||
int64_t tr_sessionGetDownloadDirFreeSpace (const tr_session * session);
|
||||
int64_t tr_sessionGetDownloadDirFreeSpace (tr_session * session);
|
||||
|
||||
/**
|
||||
* @brief Set the torrent's bandwidth priority.
|
||||
|
|
Loading…
Reference in a new issue