Replace tabs with spaces; remove trailing spaces

This commit is contained in:
Mike Gelfand
2015-01-02 11:15:31 +00:00
parent 9a3b965ce4
commit 440f482d01
42 changed files with 108 additions and 108 deletions
+4 -4
View File
@@ -389,9 +389,9 @@ reportStatus (void)
const double dn = tr_sessionGetRawSpeed_KBps (mySession, TR_DOWN);
if (up>0 || dn>0)
sd_notifyf (0, "STATUS=Uploading %.2f KBps, Downloading %.2f KBps.\n", up, dn);
sd_notifyf (0, "STATUS=Uploading %.2f KBps, Downloading %.2f KBps.\n", up, dn);
else
sd_notify (0, "STATUS=Idle.\n");
sd_notify (0, "STATUS=Idle.\n");
}
static void
@@ -574,7 +574,7 @@ main (int argc, char ** argv)
exit (1);
}
sd_notifyf (0, "MAINPID=%d\n", (int)getpid());
sd_notifyf (0, "MAINPID=%d\n", (int)getpid());
/* setup event state */
ev_base = event_base_new();
@@ -681,7 +681,7 @@ main (int argc, char ** argv)
if (event_base_dispatch(ev_base) == -1)
{
tr_logAddError("Failed to launch daemon event loop: %s", tr_strerror(errno));
goto cleanup;
goto cleanup;
}
cleanup:
+1 -1
View File
@@ -1765,7 +1765,7 @@ tr_curl_easy_init (struct evbuffer * writebuf)
if (UseSSL)
{
curl_easy_setopt (curl, CURLOPT_SSL_VERIFYHOST, 0); /* do not verify subject/hostname */
curl_easy_setopt (curl, CURLOPT_SSL_VERIFYPEER, 0); /* since most certs will be self-signed, do not verify against CA */
curl_easy_setopt (curl, CURLOPT_SSL_VERIFYPEER, 0); /* since most certs will be self-signed, do not verify against CA */
}
if (sessionId) {
char * h = tr_strdup_printf ("%s: %s", TR_RPC_SESSION_ID_HEADER, sessionId);
+5 -5
View File
@@ -110,15 +110,15 @@ Productivity_DATA = $(DESKTOP_FILES)
icon_DATA = transmission.png
icondir = $(datadir)/pixmaps
UI_FILES = transmission-ui.xml
UI_FILES = transmission-ui.xml
transmission-resources.c: transmission.gresource.xml $(UI_FILES)
transmission-resources.c: transmission.gresource.xml $(UI_FILES)
$(AM_V_GEN)glib-compile-resources --target=$@ --sourcedir=$(srcdir) \
--generate-source --c-name transmission $<
--generate-source --c-name transmission $<
transmission-resources.h: transmission.gresource.xml $(UI_FILES)
transmission-resources.h: transmission.gresource.xml $(UI_FILES)
$(AM_V_GEN)glib-compile-resources --target=$@ --sourcedir=$(srcdir) \
--generate-header --c-name transmission $<
--generate-header --c-name transmission $<
CLEANFILES += \
transmission-resources.c \
+2 -2
View File
@@ -64,7 +64,7 @@
#define SHOW_LICENSE
static const char * LICENSE =
"Copyright 2005-2014. All code is copyrighted by the respective authors.\n"
"\n"
"\n"
"Transmission can be redistributed and/or modified under the terms of the "
"GNU GPL versions 2 or 3 or by any future license endorsed by Mnemosyne LLC.\n"
"\n"
@@ -468,7 +468,7 @@ on_rpc_changed (tr_session * session G_GNUC_UNUSED,
data->type = type;
data->torrent_id = tr_torrentId (tor);
gdk_threads_add_idle (on_rpc_changed_idle, data);
return TR_RPC_NOREMOVE;
}
+1 -1
View File
@@ -12,7 +12,7 @@ StartupNotify=true
MimeType=application/x-bittorrent;x-scheme-handler/magnet;
Categories=Network;FileTransfer;P2P;GTK;
X-Ubuntu-Gettext-Domain=transmission
X-AppInstall-Keywords=torrent
X-AppInstall-Keywords=torrent
Actions=Pause;Minimize;
[Desktop Action Pause]
+1 -1
View File
@@ -48,7 +48,7 @@ extern const char * speed_T_str;
\
return q; \
}
#endif
#endif
/* macro to shut up "unused parameter" warnings */
+1 -1
View File
@@ -1351,7 +1351,7 @@ on_scrape_done (const tr_scrape_response * response, void * vsession)
if (!response->did_connect)
{
on_scrape_error (session, tier, _("Could not connect to tracker"));
}
}
else if (response->did_timeout)
{
on_scrape_error (session, tier, _("Tracker did not respond"));
+2 -2
View File
@@ -311,7 +311,7 @@ libttest_zero_torrent_init (tr_session * session)
tr_torrent * tor;
tr_ctor * ctor;
/*
/*
1048576 files-filled-with-zeroes/1048576
4096 files-filled-with-zeroes/4096
512 files-filled-with-zeroes/512
@@ -388,7 +388,7 @@ libttest_zero_torrent_populate (tr_torrent * tor, bool complete)
assert (path != NULL);
err = errno;
assert (tr_sys_path_exists (path, NULL));
errno = err;
errno = err;
tr_free (path);
}
+1 -1
View File
@@ -151,7 +151,7 @@ tr_logGetTimeStr (char * buf, int buflen)
seconds = tv.tv_sec;
tr_localtime_r (&seconds, &now_tm);
strftime (tmp, sizeof (tmp), "%Y-%m-%d %H:%M:%S.%%03d %Z", &now_tm);
strftime (tmp, sizeof (tmp), "%Y-%m-%d %H:%M:%S.%%03d %Z", &now_tm);
milliseconds = tv.tv_usec / 1000;
tr_snprintf (buf, buflen, tmp, milliseconds);
+2 -2
View File
@@ -135,7 +135,7 @@ test_single_directory_impl (const tr_tracker_info * trackers,
size_t totalSize;
size_t i;
char* tmpstr;
/* set up our local test sandbox */
sandbox = libtest_sandbox_create();
@@ -212,7 +212,7 @@ test_single_directory_impl (const tr_tracker_info * trackers,
return 0;
}
static int
test_single_directory_random_payload_impl (const tr_tracker_info * trackers,
const size_t trackerCount,
+1 -1
View File
@@ -96,7 +96,7 @@ test_metainfo (void)
return 0;
}
int
main (void)
{
+2 -2
View File
@@ -65,7 +65,7 @@ test_incomplete_dir_threadfunc (void * vdata)
tr_torrentGotBlock (data->tor, data->block);
data->done = true;
}
static int
test_incomplete_dir_impl (const char * incomplete_dir, const char * download_dir)
{
@@ -179,7 +179,7 @@ test_set_location (void)
session = libttest_session_init (NULL);
target_dir = tr_buildPath (tr_sessionGetConfigDir (session), "target", NULL);
tr_sys_dir_create (target_dir, TR_SYS_DIR_CREATE_PARENTS, 0777, NULL);
/* init a torrent. */
tor = libttest_zero_torrent_init (session);
libttest_zero_torrent_populate (tor, true);
+1 -1
View File
@@ -165,7 +165,7 @@ const unsigned char *tr_globalIPv6 (void);
#if defined (_WIN32) && !defined (QT_DLL)
/* The QT exclusion is because something clashes whith the next include */
#include <ws2tcpip.h> /* socklen_t */
#include <ws2tcpip.h> /* socklen_t */
#endif
+1 -1
View File
@@ -3281,7 +3281,7 @@ getReconnectIntervalSecs (const struct peer_atom * atom, const time_t now)
/* penalize peers that were unreachable the last time we tried */
if (unreachable)
step += 2;
switch (step)
{
case 0: sec = 0; break;
+1 -1
View File
@@ -183,7 +183,7 @@ void tr_peerMgrGotBadPiece (tr_torrent * tor,
void tr_peerMgrPieceCompleted (tr_torrent * tor,
tr_piece_index_t pieceIndex);
/* @} */
+3 -3
View File
@@ -690,7 +690,7 @@ updateFastSet (tr_peerMsgs * msgs UNUSED)
**** ACTIVE
***/
static bool
static bool
tr_peerMsgsCalculateActive (const tr_peerMsgs * msgs, tr_direction direction)
{
bool is_active;
@@ -1829,7 +1829,7 @@ updateDesiredRequestCount (tr_peerMsgs * msgs)
/* honor the session limits, if enabled */
if (tr_torrentUsesSessionLimits (torrent) &&
tr_sessionGetActiveSpeedLimit_Bps (torrent->session, TR_PEER_TO_CLIENT, &irate_Bps))
tr_sessionGetActiveSpeedLimit_Bps (torrent->session, TR_PEER_TO_CLIENT, &irate_Bps))
rate_Bps = MIN (rate_Bps, irate_Bps);
/* use this desired rate to figure out how
@@ -2469,7 +2469,7 @@ pexPulse (evutil_socket_t foo UNUSED, short bar UNUSED, void * vmsgs)
static bool
peermsgs_is_transferring_pieces (const struct tr_peer * peer,
uint64_t now,
tr_direction direction,
tr_direction direction,
unsigned int * setme_Bps)
{
unsigned int Bps = 0;
+7 -7
View File
@@ -253,13 +253,13 @@ getquota (const char * device)
if (quotactl(device, QCMD(Q_GETQUOTA, USRQUOTA), getuid(), (caddr_t) &dq) == 0)
{
#elif defined(__sun)
struct quotctl op;
int fd = open(device, O_RDONLY);
if (fd < 0)
return -1;
op.op = Q_GETQUOTA;
op.uid = getuid();
op.addr = (caddr_t) &dq;
struct quotctl op;
int fd = open(device, O_RDONLY);
if (fd < 0)
return -1;
op.op = Q_GETQUOTA;
op.uid = getuid();
op.addr = (caddr_t) &dq;
if (ioctl(fd, Q_QUOTACTL, &op) == 0)
{
close(fd);
+1 -1
View File
@@ -488,7 +488,7 @@ tr_quark_new (const void * str, size_t len)
return ret;
}
const char *
tr_quark_get_string (tr_quark q, size_t * len)
{
+5 -5
View File
@@ -117,7 +117,7 @@ create_torrent_from_base64_metainfo (tr_ctor * ctor, const char * metainfo_base6
assert (!err);
/* cleanup */
tr_free (metainfo);
tr_free (metainfo);
return tor;
}
@@ -183,7 +183,7 @@ test_single_filename_torrent (void)
**** Now try a rename that should succeed
***/
tmpstr = tr_buildPath (tor->currentDir, "hello-world.txt", NULL);
tmpstr = tr_buildPath (tor->currentDir, "hello-world.txt", NULL);
check (tr_sys_path_exists (tmpstr, NULL));
check_streq ("hello-world.txt", tr_torrentName(tor));
check_int_eq (0, torrentRenameAndWait (tor, tor->info.name, "foobar"));
@@ -193,7 +193,7 @@ test_single_filename_torrent (void)
check_streq ("foobar", tr_torrentName(tor)); /* confirm the torrent's name is now 'foobar' */
check_streq ("foobar", tor->info.files[0].name); /* confirm the file's name is now 'foobar' in our struct */
check (strstr (tor->info.torrent, "foobar") == NULL); /* confirm the name in the .torrent file hasn't changed */
tmpstr = tr_buildPath (tor->currentDir, "foobar", NULL);
tmpstr = tr_buildPath (tor->currentDir, "foobar", NULL);
check (tr_sys_path_exists (tmpstr, NULL)); /* confirm the file's name is now 'foobar' on the disk */
tr_free (tmpstr);
check (testFileExistsAndConsistsOfThisString (tor, 0, "hello, world!\n")); /* confirm the contents are right */
@@ -209,7 +209,7 @@ test_single_filename_torrent (void)
**** ...and rename it back again
***/
tmpstr = tr_buildPath (tor->currentDir, "foobar", NULL);
tmpstr = tr_buildPath (tor->currentDir, "foobar", NULL);
check (tr_sys_path_exists (tmpstr, NULL));
check_int_eq (0, torrentRenameAndWait (tor, "foobar", "hello-world.txt"));
check (!tr_sys_path_exists (tmpstr, NULL));
@@ -501,7 +501,7 @@ test_partial_file (void)
const char * strings[3];
/***
**** create our test torrent with an incomplete .part file
**** create our test torrent with an incomplete .part file
***/
tor = libttest_zero_torrent_init (session);
+1 -1
View File
@@ -936,7 +936,7 @@ missing_settings_key (const tr_quark q)
{
const char * str = tr_quark_get_string (q, NULL);
tr_logAddNamedError (MY_NAME, _("Couldn't find settings key \"%s\""), str);
}
}
tr_rpc_server *
tr_rpcInit (tr_session * session, tr_variant * settings)
+9 -9
View File
@@ -251,14 +251,14 @@ queueMoveBottom (tr_session * session,
return NULL;
}
static int
compareTorrentByQueuePosition (const void * va, const void * vb)
{
const tr_torrent * a = * (const tr_torrent **) va;
const tr_torrent * b = * (const tr_torrent **) vb;
static int
compareTorrentByQueuePosition (const void * va, const void * vb)
{
const tr_torrent * a = * (const tr_torrent **) va;
const tr_torrent * b = * (const tr_torrent **) vb;
return a->queuePosition - b->queuePosition;
}
return a->queuePosition - b->queuePosition;
}
static const char*
torrentStart (tr_session * session,
@@ -273,7 +273,7 @@ torrentStart (tr_session * session,
assert (idle_data == NULL);
torrents = getTorrents (session, args_in, &torrentCount);
qsort (torrents, torrentCount, sizeof (tr_torrent *), compareTorrentByQueuePosition);
qsort (torrents, torrentCount, sizeof (tr_torrent *), compareTorrentByQueuePosition);
for (i=0; i<torrentCount; ++i)
{
tr_torrent * tor = torrents[i];
@@ -301,7 +301,7 @@ torrentStartNow (tr_session * session,
assert (idle_data == NULL);
torrents = getTorrents (session, args_in, &torrentCount);
qsort (torrents, torrentCount, sizeof (tr_torrent *), compareTorrentByQueuePosition);
qsort (torrents, torrentCount, sizeof (tr_torrent *), compareTorrentByQueuePosition);
for (i=0; i<torrentCount; ++i)
{
tr_torrent * tor = torrents[i];
+2 -2
View File
@@ -1762,7 +1762,7 @@ tr_sessionGetTorrents (tr_session * session, int * setme_n)
torrents[i] = tor = tr_torrentNext (session, tor);
return torrents;
}
}
static int
compareTorrentByCur (const void * va, const void * vb)
@@ -2253,7 +2253,7 @@ loadBlocklists (tr_session * session)
{
char * path;
char * load = NULL;
if (name[0] == '.') /* ignore dotfiles */
continue;
+14 -14
View File
@@ -1929,19 +1929,19 @@ closeTorrent (void * vtor)
}
void
tr_torrentFree (tr_torrent * tor)
tr_torrentFree (tr_torrent * tor)
{
if (tr_isTorrent (tor))
{
tr_session * session = tor->session;
assert (tr_isSession (session));
tr_sessionLock (session);
if (tr_isTorrent (tor))
{
tr_session * session = tor->session;
assert (tr_isSession (session));
tr_sessionLock (session);
tr_torrentClearCompletenessCallback (tor);
tr_runInEventThread (session, closeTorrent, tor);
tr_torrentClearCompletenessCallback (tor);
tr_runInEventThread (session, closeTorrent, tor);
tr_sessionUnlock (session);
}
tr_sessionUnlock (session);
}
}
struct remove_data
@@ -1958,7 +1958,7 @@ removeTorrent (void * vdata)
{
struct remove_data * data = vdata;
tr_session * session = data->tor->session;
tr_sessionLock (session);
tr_sessionLock (session);
if (data->deleteFlag)
tr_torrentDeleteLocalData (data->tor, data->deleteFunc);
@@ -1967,7 +1967,7 @@ removeTorrent (void * vdata)
closeTorrent (data->tor);
tr_free (data);
tr_sessionUnlock (session);
tr_sessionUnlock (session);
}
void
@@ -3700,13 +3700,13 @@ renameTorrentFileString (tr_torrent * tor,
tr_free (tmp);
}
if (!strcmp (file->name, name))
{
tr_free (name);
}
else
{
{
tr_free (file->name);
file->name = name;
file->is_renamed = true;
+4 -4
View File
@@ -303,10 +303,10 @@ tr_torBlockCountBytes (const tr_torrent * tor, const tr_block_index_t block)
: tor->blockSize;
}
static inline void tr_torrentLock (const tr_torrent * tor)
{
tr_sessionLock (tor->session);
}
static inline void tr_torrentLock (const tr_torrent * tor)
{
tr_sessionLock (tor->session);
}
static inline bool tr_torrentIsLocked (const tr_torrent * tor)
{
return tr_sessionIsLocked (tor->session);
+1 -1
View File
@@ -32,7 +32,7 @@ THE SOFTWARE.
#ifdef _WIN32
#include <inttypes.h>
#include <ws2tcpip.h>
typedef uint16_t in_port_t; /* all missing */
typedef uint16_t in_port_t; /* all missing */
#else
#include <sys/time.h>
#include <unistd.h> /* close () */
+4 -4
View File
@@ -109,10 +109,10 @@ piperead (int s, char *buf, int len)
case WSAEWOULDBLOCK:
errno = EAGAIN;
break;
case WSAECONNRESET:
/* EOF on the pipe! (win32 socket based implementation) */
ret = 0;
/* fall through */
case WSAECONNRESET:
/* EOF on the pipe! (win32 socket based implementation) */
ret = 0;
/* fall through */
default:
errno = werror;
break;
+4 -4
View File
@@ -116,14 +116,14 @@ tr_upnpGetSpecificPortMappingEntry (tr_upnp * handle, const char * proto)
#if (MINIUPNPC_API_VERSION >= 10) /* adds remoteHost arg */
err = UPNP_GetSpecificPortMappingEntry (handle->urls.controlURL,
handle->data.first.servicetype,
err = UPNP_GetSpecificPortMappingEntry (handle->urls.controlURL,
handle->data.first.servicetype,
portStr,
proto,
NULL /*remoteHost*/,
NULL /*remoteHost*/,
intClient,
intPort,
NULL /*desc*/,
NULL /*desc*/,
NULL /*enabled*/,
NULL /*duration*/);
+2 -2
View File
@@ -216,14 +216,14 @@ extract_escaped_string (const char * in,
UTF8 str8_buf[8] = { 0, 0, 0, 0, 0, 0, 0, 0 };
UTF8 * str8_walk = str8_buf;
UTF8 * str8_end = str8_buf + 8;
if (ConvertUTF32toUTF8 (&str32_walk, str32_end, &str8_walk, str8_end, 0) == 0)
{
const size_t len = str8_walk - str8_buf;
evbuffer_add (buf, str8_buf, len);
unescaped = true;
}
in += 6;
break;
}
+1 -1
View File
@@ -22,7 +22,7 @@
#define __LIBTRANSMISSION_VARIANT_MODULE___
#include "transmission.h"
#include "ConvertUTF.h"
#include "ConvertUTF.h"
#include "error.h"
#include "file.h"
#include "log.h"
+2 -2
View File
@@ -49,7 +49,7 @@ struct tr_variant_string
size_t len;
union { char buf[16]; const char * str; } str;
};
/* these are PRIVATE IMPLEMENTATION details that should not be touched.
* I'll probably change them just to break your code! HA HA HA!
@@ -200,7 +200,7 @@ tr_variantIsString (const tr_variant * b)
bool tr_variantGetStr (const tr_variant * variant,
const char ** setme_str,
size_t * setme_len);
void tr_variantInitStr (tr_variant * initme,
const void * str,
int str_len);
+1 -1
View File
@@ -275,7 +275,7 @@ tr_webRunImpl (tr_session * session,
while (session->web == NULL)
tr_wait_msec (20);
}
task = tr_new0 (struct tr_web_task, 1);
task->session = session;
task->torrentId = torrentId;
+1 -1
View File
@@ -285,7 +285,7 @@ on_content_changed (struct evbuffer * buf,
that will be needed when writing the block in a different thread */
evbuffer_remove_buffer (task->content, data->content,
block_size * completed);
tr_runInEventThread (w->session, write_block_func, data);
task->blocks_done += completed;
}
+2 -2
View File
@@ -2,7 +2,7 @@ VOLUNTEERS WANTED
- Qt developers and translators are needed
- If you find a bug, please report it at http://trac.transmissionbt.com/
ABOUT TRANSMISSION-QT
Transmission-qt is a GUI for Transmission loosely based on the GTK+ client.
@@ -42,4 +42,4 @@ BUILDING ON UNIX
4. In the qt/ directory, type "make"
5. In the qt/ directory, as root, type "INSTALL_ROOT=/usr make install"
(Feel free to replace /usr with /usr/local or /opt or whatever)
+1 -1
View File
@@ -353,7 +353,7 @@ MyApp::onTorrentsAdded (const QSet<int>& torrents)
onNewTorrentChanged (id);
if (!tor->isSeed ())
connect (tor, SIGNAL (torrentCompleted (int)), this, SLOT (onTorrentCompleted (int)));
connect (tor, SIGNAL (torrentCompleted (int)), this, SLOT (onTorrentCompleted (int)));
}
}
}
+1 -1
View File
@@ -1,5 +1,5 @@
DHT_LIBS = @DHT_LIBS_QT@
LIBB64_LIBS = @LIBB64_LIBS_QT@
LIBUTP_LIBS = @LIBUTP_LIBS_QT@
LIBUTP_LIBS = @LIBUTP_LIBS_QT@
LIBUPNP_LIBS = @LIBUPNP_LIBS_QT@
LIBNATPMP_LIBS = @LIBNATPMP_LIBS_QT@
+4 -4
View File
@@ -195,7 +195,7 @@ FileTreeItem::progress () const
QString
FileTreeItem::sizeString () const
{
QString str;
QString str;
if (myChildren.isEmpty())
{
@@ -437,7 +437,7 @@ FileTreeModel::setEditable (bool editable)
FileTreeItem *
FileTreeModel::itemFromIndex (const QModelIndex& index) const
{
return static_cast<FileTreeItem*>(index.internalPointer());
return static_cast<FileTreeItem*>(index.internalPointer());
}
QVariant
@@ -504,7 +504,7 @@ FileTreeModel::headerData (int column, Qt::Orientation orientation, int role) co
break;
case COL_PRIORITY:
data.setValue (tr("Priority"));
data.setValue (tr("Priority"));
break;
default:
@@ -634,7 +634,7 @@ FileTreeModel::addFile (int fileIndex,
item = findItemForFileIndex (fileIndex);
if (item) // this file is already in the tree, we've added this
if (item) // this file is already in the tree, we've added this
{
QModelIndex indexWithChangedParents;
while (!tokens.isEmpty())
+1 -1
View File
@@ -614,7 +614,7 @@ PrefsDialog::createDownloadingTab ()
hig->addSectionDivider ();
hig->addSectionTitle (tr ("Download Queue"));
hig->addRow (tr ("Ma&ximum active downloads:"), spinBoxNew (Prefs::DOWNLOAD_QUEUE_SIZE, 1, INT_MAX, 1));
hig->addRow (tr ("Downloads sharing data in the last &N minutes are active:"), spinBoxNew (Prefs::QUEUE_STALLED_MINUTES, 1, INT_MAX, 10));
+1 -1
View File
@@ -21,7 +21,7 @@ greaterThan(QT_MAJOR_VERSION, 4) {
TRANSMISSION_TOP = ..
include(config.pri)
include(config.pri)
INCLUDEPATH = $${EVENT_TOP}/include $${INCLUDEPATH}
INCLUDEPATH += $${TRANSMISSION_TOP}
+5 -5
View File
@@ -534,12 +534,12 @@ Session::sendTorrentRequest (const char * request, const QSet<int>& ids)
}
void Session::pauseTorrents (const QSet<int>& ids) { sendTorrentRequest ("torrent-stop", ids); }
void Session::startTorrents (const QSet<int>& ids) { sendTorrentRequest ("torrent-start", ids); }
void Session::startTorrents (const QSet<int>& ids) { sendTorrentRequest ("torrent-start", ids); }
void Session::startTorrentsNow (const QSet<int>& ids) { sendTorrentRequest ("torrent-start-now", ids); }
void Session::queueMoveTop (const QSet<int>& ids) { sendTorrentRequest ("queue-move-top", ids); }
void Session::queueMoveUp (const QSet<int>& ids) { sendTorrentRequest ("queue-move-up", ids); }
void Session::queueMoveDown (const QSet<int>& ids) { sendTorrentRequest ("queue-move-down", ids); }
void Session::queueMoveBottom (const QSet<int>& ids) { sendTorrentRequest ("queue-move-bottom", ids); }
void Session::queueMoveTop (const QSet<int>& ids) { sendTorrentRequest ("queue-move-top", ids); }
void Session::queueMoveUp (const QSet<int>& ids) { sendTorrentRequest ("queue-move-up", ids); }
void Session::queueMoveDown (const QSet<int>& ids) { sendTorrentRequest ("queue-move-down", ids); }
void Session::queueMoveBottom (const QSet<int>& ids) { sendTorrentRequest ("queue-move-bottom", ids); }
void
Session::refreshActiveTorrents ()
+1 -1
View File
@@ -251,7 +251,7 @@ TorrentFilter::countTorrentsPerMode (int * setmeCounts) const
std::fill_n (setmeCounts, static_cast<std::size_t>(FilterMode::NUM_MODES), 0);
for (int row(0); ; ++row)
{
{
QModelIndex index (sourceModel()->index(row, 0));
if (!index.isValid())
break;
+1 -1
View File
@@ -219,7 +219,7 @@ Utils::isValidUtf8 (const char * s)
for (int m = 1; m < n; m++)
if ((c[m] & 0xc0) != 0x80)
return false;
}
}
return true;
}
+3 -3
View File
@@ -86,12 +86,12 @@ parseCommandLine (int argc, const char ** argv)
break;
case 's':
if (optarg)
{
if (optarg)
{
char * endptr = NULL;
piecesize_kib = strtoul (optarg, &endptr, 10);
if (endptr && *endptr=='M')
piecesize_kib *= KiB;
piecesize_kib *= KiB;
}
break;