Changeset 8869 for trunk/libtransmission/torrent.c
- Timestamp:
- Aug 5, 2009, 1:25:36 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/libtransmission/torrent.c
r8864 r8869 286 286 case TR_TRACKER_WARNING: 287 287 tr_torerr( tor, _( "Tracker warning: \"%s\"" ), event->text ); 288 tor->error = -1; 289 tr_strlcpy( tor->errorString, event->text, 290 sizeof( tor->errorString ) ); 288 tor->error = TR_STAT_TRACKER_WARNING; 289 tr_strlcpy( tor->errorString, event->text, sizeof( tor->errorString ) ); 291 290 break; 292 291 293 292 case TR_TRACKER_ERROR: 294 293 tr_torerr( tor, _( "Tracker error: \"%s\"" ), event->text ); 295 tor->error = -2; 296 tr_strlcpy( tor->errorString, event->text, 297 sizeof( tor->errorString ) ); 294 tor->error = TR_STAT_TRACKER_ERROR; 295 tr_strlcpy( tor->errorString, event->text, sizeof( tor->errorString ) ); 298 296 break; 299 297 300 298 case TR_TRACKER_ERROR_CLEAR: 301 tor->error = 0;299 tor->error = TR_STAT_OK; 302 300 tor->errorString[0] = '\0'; 303 301 break; … … 605 603 tr_ctorInitTorrentWanted( ctor, tor ); 606 604 607 tor->error = 0;605 tor->error = TR_STAT_OK; 608 606 609 607 tr_bitfieldConstruct( &tor->checkedPieces, tor->info.pieceCount ); … … 860 858 s->id = tor->uniqueId; 861 859 s->activity = tr_torrentGetActivity( tor ); 862 s->error = tor->error; 863 memcpy( s->errorString, tor->errorString, 864 sizeof( s->errorString ) ); 860 s->error = tor->error; 861 memcpy( s->errorString, tor->errorString, sizeof( s->errorString ) ); 865 862 866 863 tc = tor->tracker; … … 1248 1245 tor->isRunning = TRUE; 1249 1246 tor->needsSeedRatioCheck = TRUE; 1250 *tor->errorString = '\0'; 1247 tor->error = TR_STAT_OK; 1248 tor->errorString[0] = '\0'; 1251 1249 tr_torrentResetTransferStats( tor ); 1252 1250 tor->completeness = tr_cpGetStatus( &tor->completion );
Note: See TracChangeset
for help on using the changeset viewer.