*Plugin: remove redundant "line %i" from error messages
The MPD core will add this as a prefeix.
This commit is contained in:
@@ -75,16 +75,14 @@ vorbis_encoder_configure(struct vorbis_encoder *encoder,
|
||||
encoder->quality > 10.0) {
|
||||
error.Format(config_domain,
|
||||
"quality \"%s\" is not a number in the "
|
||||
"range -1 to 10, line %i",
|
||||
value, param.line);
|
||||
"range -1 to 10",
|
||||
value);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (param.GetBlockValue("bitrate") != nullptr) {
|
||||
error.Format(config_domain,
|
||||
"quality and bitrate are "
|
||||
"both defined (line %i)",
|
||||
param.line);
|
||||
error.Set(config_domain,
|
||||
"quality and bitrate are both defined");
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
@@ -92,10 +90,8 @@ vorbis_encoder_configure(struct vorbis_encoder *encoder,
|
||||
|
||||
value = param.GetBlockValue("bitrate");
|
||||
if (value == nullptr) {
|
||||
error.Format(config_domain,
|
||||
"neither bitrate nor quality defined "
|
||||
"at line %i",
|
||||
param.line);
|
||||
error.Set(config_domain,
|
||||
"neither bitrate nor quality defined");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -104,9 +100,8 @@ vorbis_encoder_configure(struct vorbis_encoder *encoder,
|
||||
char *endptr;
|
||||
encoder->bitrate = g_ascii_strtoll(value, &endptr, 10);
|
||||
if (*endptr != '\0' || encoder->bitrate <= 0) {
|
||||
error.Format(config_domain,
|
||||
"bitrate at line %i should be a positive integer",
|
||||
param.line);
|
||||
error.Set(config_domain,
|
||||
"bitrate should be a positive integer");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user