1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-25 16:48:44 +02:00

Fix warnings for nonexhaustive switches on enumerations

This commit is contained in:
Paul Licameli 2016-02-26 14:44:31 -05:00
parent dfc84d030c
commit 3cc4754ac7
4 changed files with 14 additions and 0 deletions

View File

@ -471,6 +471,8 @@ void TrackArtist::DrawTrack(const Track * t,
case WaveTrack::Spectrum:
DrawSpectrum(wt, dc, rect, selectedRegion, zoomInfo);
break;
default:
wxASSERT(false);
}
#if defined(__WXMAC__)

View File

@ -589,6 +589,12 @@ static int encode_audio(AVCodecContext *avctx, AVPacket *pkt, int16_t *audio_sam
case AV_SAMPLE_FMT_FLTP:
((float*)(frame->data[ch]))[i] = audio_samples[ch + i*avctx->channels] / 32767.;
break;
case AV_SAMPLE_FMT_NONE:
case AV_SAMPLE_FMT_DBL:
case AV_SAMPLE_FMT_DBLP:
case AV_SAMPLE_FMT_NB:
wxASSERT(false);
break;
}
}
}

View File

@ -215,6 +215,9 @@ void MyFLACFile::metadata_callback(const FLAC__StreamMetadata *metadata)
case FLAC__METADATA_TYPE_PICTURE: // ignore pictures
case FLAC__METADATA_TYPE_UNDEFINED: // do nothing with this either
break;
case FLAC__MAX_METADATA_TYPE: // suppress compiler warning
wxASSERT(false);
}
}

View File

@ -79,6 +79,9 @@ void ODFLACFile::metadata_callback(const FLAC__StreamMetadata *metadata)
case FLAC__METADATA_TYPE_PICTURE: // ignore pictures
case FLAC__METADATA_TYPE_UNDEFINED: // do nothing with this either
break;
case FLAC__MAX_METADATA_TYPE: // suppress compiler warning
break;
}
}