mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-10-18 07:06:18 +00:00
* Fixed warnings in snprintf statements.
* Don't send numwant in tracker STOPPED requests. * Reintroudced clearing of epoll event list when a socket is closed as it might cause race conditions. git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1097 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
@@ -114,6 +114,10 @@ apply_d_change_link(int changeType, core::Download* download, const torrent::Obj
|
|||||||
target = rpc::call_command_string("d.get_base_path", rpc::make_target(download));
|
target = rpc::call_command_string("d.get_base_path", rpc::make_target(download));
|
||||||
link = rak::path_expand(prefix + rpc::call_command_string("d.get_base_filename", rpc::make_target(download)) + postfix);
|
link = rak::path_expand(prefix + rpc::call_command_string("d.get_base_filename", rpc::make_target(download)) + postfix);
|
||||||
|
|
||||||
|
// } else if (type == "directory_path") {
|
||||||
|
// target = rpc::call_command_string("d.get_directory", rpc::make_target(download));
|
||||||
|
// link = rak::path_expand(prefix + rpc::call_command_string("d.get_base_path", rpc::make_target(download)) + postfix);
|
||||||
|
|
||||||
} else if (type == "tied") {
|
} else if (type == "tied") {
|
||||||
link = rak::path_expand(rpc::call_command_string("d.get_tied_to_file", rpc::make_target(download)));
|
link = rak::path_expand(rpc::call_command_string("d.get_tied_to_file", rpc::make_target(download)));
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -84,7 +84,8 @@ print_buffer(char* first, char* last, const char* format) {
|
|||||||
if (first >= last)
|
if (first >= last)
|
||||||
return first;
|
return first;
|
||||||
|
|
||||||
int s = snprintf(first, last - first, format);
|
// Adding 'i' format to suppress a GCC warning.
|
||||||
|
int s = snprintf(first, last - first, format, 0);
|
||||||
|
|
||||||
if (s < 0)
|
if (s < 0)
|
||||||
return first;
|
return first;
|
||||||
|
|||||||
Reference in New Issue
Block a user