mirror of
https://github.com/transmission/transmission
synced 2024-12-26 09:37:56 +00:00
(trunk libT) #2508 "atom->port never updated" -- (1) fix r9434 bug that used the wrong byte ordering scheme for port numbers. This is why most of the .resume file's peers are worthless in betas 1 and 2. :( (2) in the resume file, change the dictionary key for peers so that the worthless peers won't be reloaded on startup in beta 3.
This commit is contained in:
parent
f3e8a29e0f
commit
d6f7df8c9a
3 changed files with 4 additions and 4 deletions
|
@ -51,7 +51,7 @@ enum
|
|||
typedef struct tr_pex
|
||||
{
|
||||
tr_address addr;
|
||||
tr_port port;
|
||||
tr_port port; /* this field is in network byte order */
|
||||
uint8_t flags;
|
||||
}
|
||||
tr_pex;
|
||||
|
|
|
@ -975,8 +975,8 @@ parseLtepHandshake( tr_peermsgs * msgs,
|
|||
|
||||
/* get peer's listening port */
|
||||
if( tr_bencDictFindInt( &val, "p", &i ) ) {
|
||||
fireClientGotPort( msgs, (tr_port)i );
|
||||
pex.port = htons( (uint16_t)i );
|
||||
fireClientGotPort( msgs, pex.port );
|
||||
dbgmsg( msgs, "peer's port is now %d", (int)i );
|
||||
}
|
||||
|
||||
|
|
|
@ -34,8 +34,8 @@
|
|||
#define KEY_INCOMPLETE_DIR "incomplete-dir"
|
||||
#define KEY_MAX_PEERS "max-peers"
|
||||
#define KEY_PAUSED "paused"
|
||||
#define KEY_PEERS "peers"
|
||||
#define KEY_PEERS6 "peers6"
|
||||
#define KEY_PEERS "peers2"
|
||||
#define KEY_PEERS6 "peers2-6"
|
||||
#define KEY_FILE_PRIORITIES "priority"
|
||||
#define KEY_BANDWIDTH_PRIORITY "bandwidth-priority"
|
||||
#define KEY_PROGRESS "progress"
|
||||
|
|
Loading…
Reference in a new issue