Changeset 11240


Ignore:
Timestamp:
Sep 20, 2010, 1:46:08 PM (12 years ago)
Author:
charles
Message:

(trunk qt) silence a couple of gcc warnings by adding reasonable defaults at the bottom of a switch statement in case bad tr_ratiolimits or FilterModes? get used in the switch

Location:
trunk/qt
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/qt/torrent-filter.cc

    r11196 r11240  
    145145    switch( m.mode( ) )
    146146    {
    147         case FilterMode::SHOW_ALL:
    148             accepts = true;
    149             break;
    150147        case FilterMode::SHOW_ACTIVE:
    151148            accepts = tor->peersWeAreUploadingTo( ) > 0 || tor->peersWeAreDownloadingFrom( ) > 0 || tor->isVerifying( );
     
    171168        case FilterMode::SHOW_ERROR:
    172169            accepts = tor->hasError( );
     170            break;
     171        default: // FilterMode::SHOW_ALL
     172            accepts = true;
    173173            break;
    174174    }
  • trunk/qt/torrent.cc

    r11194 r11240  
    343343            break;
    344344
    345         case TR_RATIOLIMIT_UNLIMITED:
     345        default: // TR_RATIOLIMIT_UNLIMITED:
    346346            isLimited = false;
    347347            break;
Note: See TracChangeset for help on using the changeset viewer.