summaryrefslogtreecommitdiff
path: root/src/metaflac
diff options
context:
space:
mode:
authorJosh Coalson <jcoalson@users.sourceforce.net>2002-12-23 19:52:20 +0000
committerJosh Coalson <jcoalson@users.sourceforce.net>2002-12-23 19:52:20 +0000
commitc191ab4f78867c801b941d03e4a9e0c7ceee00b0 (patch)
tree0741823c4f06994283b9bffe11440405cac6ff1b /src/metaflac
parent91d37b241862dee1f8e4bfecd941969446c74de5 (diff)
downloadflac-c191ab4f78867c801b941d03e4a9e0c7ceee00b0.tar.gz
double-protect a naked assert
Diffstat (limited to 'src/metaflac')
-rw-r--r--src/metaflac/operations.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/metaflac/operations.c b/src/metaflac/operations.c
index 87ac1c73..1147be46 100644
--- a/src/metaflac/operations.c
+++ b/src/metaflac/operations.c
@@ -421,8 +421,12 @@ FLAC__bool do_shorthand_operation__add_replay_gain(char **filenames, unsigned nu
}
FLAC__ASSERT(bits_per_sample >= FLAC__MIN_BITS_PER_SAMPLE && bits_per_sample <= FLAC__MAX_BITS_PER_SAMPLE);
- if(!grabbag__replaygain_init(sample_rate))
+ if(!grabbag__replaygain_init(sample_rate)) {
FLAC__ASSERT(0);
+ /* double protection */
+ fprintf(stderr, "internal error\n");
+ return false;
+ }
if(
0 == (title_gains = (float*)malloc(sizeof(float) * num_files)) ||