forked from premiere/premiere-libtorrent
fix whitespace
This commit is contained in:
parent
80710abcbf
commit
b8dad50757
|
@ -82,14 +82,14 @@ namespace libtorrent
|
||||||
struct stat s;
|
struct stat s;
|
||||||
if (lstat(convert_to_native(p).c_str(), &s) < 0) return 0;
|
if (lstat(convert_to_native(p).c_str(), &s) < 0) return 0;
|
||||||
int file_attr = 0;
|
int file_attr = 0;
|
||||||
if (s.st_mode & S_IXUSR)
|
if (s.st_mode & S_IXUSR)
|
||||||
file_attr += file_storage::attribute_executable;
|
file_attr += file_storage::attribute_executable;
|
||||||
if (S_ISLNK(s.st_mode))
|
if (S_ISLNK(s.st_mode))
|
||||||
file_attr += file_storage::attribute_symlink;
|
file_attr += file_storage::attribute_symlink;
|
||||||
return file_attr;
|
return file_attr;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef TORRENT_WINDOWS
|
#ifndef TORRENT_WINDOWS
|
||||||
std::string get_symlink_path_impl(char const* path)
|
std::string get_symlink_path_impl(char const* path)
|
||||||
{
|
{
|
||||||
|
@ -150,7 +150,7 @@ namespace libtorrent
|
||||||
|
|
||||||
// mask all bits to check if the file is a symlink
|
// mask all bits to check if the file is a symlink
|
||||||
if ((file_flags & file_storage::attribute_symlink)
|
if ((file_flags & file_storage::attribute_symlink)
|
||||||
&& (flags & create_torrent::symlinks))
|
&& (flags & create_torrent::symlinks))
|
||||||
{
|
{
|
||||||
std::string sym_path = get_symlink_path(f);
|
std::string sym_path = get_symlink_path(f);
|
||||||
fs.add_file(l, 0, file_flags, s.mtime, sym_path);
|
fs.add_file(l, 0, file_flags, s.mtime, sym_path);
|
||||||
|
@ -433,7 +433,7 @@ namespace libtorrent
|
||||||
return dict;
|
return dict;
|
||||||
|
|
||||||
if (!m_urls.empty()) dict["announce"] = m_urls.front().first;
|
if (!m_urls.empty()) dict["announce"] = m_urls.front().first;
|
||||||
|
|
||||||
if (!m_nodes.empty())
|
if (!m_nodes.empty())
|
||||||
{
|
{
|
||||||
entry& nodes = dict["nodes"];
|
entry& nodes = dict["nodes"];
|
||||||
|
@ -475,7 +475,7 @@ namespace libtorrent
|
||||||
|
|
||||||
if (!m_created_by.empty())
|
if (!m_created_by.empty())
|
||||||
dict["created by"] = m_created_by;
|
dict["created by"] = m_created_by;
|
||||||
|
|
||||||
if (!m_url_seeds.empty())
|
if (!m_url_seeds.empty())
|
||||||
{
|
{
|
||||||
if (m_url_seeds.size() == 1)
|
if (m_url_seeds.size() == 1)
|
||||||
|
|
Loading…
Reference in New Issue