- Timestamp:
- Dec 17, 2018, 11:00:02 PM (6 years ago)
- Branches:
- feature/autosink, feature/cnn, feature/crepe, fix/ffmpeg5, master
- Children:
- 20ce2ad
- Parents:
- d013a93
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/io/sink.c
rd013a93 rd286fe4 94 94 static const char_t *aubio_get_extension(const char_t *filename) 95 95 { 96 if (!filename) return NULL; 96 97 // find last occurence of dot character 97 98 const char_t *ext = strrchr(filename, '.'); … … 109 110 // check if this uri could be for us 110 111 uint_t match_oggstream = 0; 111 if ( strcmp (uri_ext, "ogg") == 0) match_oggstream = 1;112 if (uri_ext && strcmp (uri_ext, "ogg") == 0) match_oggstream = 1; 112 113 if (match_oggstream) { 113 114 s->sink = (void *)new_aubio_sink_vorbis(uri, samplerate); … … 129 130 // check if this uri could be for us 130 131 uint_t match_flacstream = 0; 131 if ( strcmp (uri_ext, "flac") == 0) match_flacstream = 1;132 if (uri_ext && strcmp (uri_ext, "flac") == 0) match_flacstream = 1; 132 133 if (match_flacstream) { 133 134 s->sink = (void *)new_aubio_sink_flac(uri, samplerate);
Note: See TracChangeset
for help on using the changeset viewer.