diff --git a/man/metaflac.sgml b/man/metaflac.sgml
index f4f2e7e5..c3ada13b 100644
--- a/man/metaflac.sgml
+++ b/man/metaflac.sgml
@@ -268,10 +268,10 @@ manpage.1: manpage.sgml
- Import a cuesheet from a file. Only one FLAC file may be
- specified. A seekpoint will be added for each index point in
- the cuesheet to the SEEKTABLE unless --no-cued-seekpoints is
- specified.
+ Import a cuesheet from a file. Use '-' for stdin. Only one
+ FLAC file may be specified. A seekpoint will be added for each
+ index point in the cuesheet to the SEEKTABLE unless
+ --no-cued-seekpoints is specified.
@@ -280,7 +280,7 @@ manpage.1: manpage.sgml
Export CUESHEET block to a cuesheet file, suitable for use by
- CD authoring software. Use '-' for stdin. Only one FLAC file
+ CD authoring software. Use '-' for stdout. Only one FLAC file
may be specified on the command line.
@@ -365,7 +365,7 @@ manpage.1: manpage.sgml
- An optional comma-separated list of block types to included
+ An optional comma-separated list of block types to be included
or ignored with this option. Use only one of --block-type or
--except-block-type. The valid block types are: STREAMINFO,
PADDING, APPLICATION, SEEKTABLE, VORBIS_COMMENT. You may
diff --git a/src/metaflac/options.c b/src/metaflac/options.c
index eddfe783..8e6f59ad 100644
--- a/src/metaflac/options.c
+++ b/src/metaflac/options.c
@@ -183,7 +183,7 @@ FLAC__bool parse_options(int argc, char *argv[], CommandLineOptions *options)
if(options->num_files > 0) {
unsigned i = 0;
- if(0 == (options->filenames = malloc(sizeof(char *) * options->num_files)))
+ if(0 == (options->filenames = (char**)malloc(sizeof(char*) * options->num_files)))
die("out of memory allocating space for file names list");
while(share__optind < argc)
options->filenames[i++] = local_strdup(argv[share__optind++]);
@@ -655,14 +655,14 @@ void append_new_operation(CommandLineOptions *options, Operation operation)
{
if(options->ops.capacity == 0) {
options->ops.capacity = 50;
- if(0 == (options->ops.operations = malloc(sizeof(Operation) * options->ops.capacity)))
+ if(0 == (options->ops.operations = (Operation*)malloc(sizeof(Operation) * options->ops.capacity)))
die("out of memory allocating space for option list");
memset(options->ops.operations, 0, sizeof(Operation) * options->ops.capacity);
}
if(options->ops.capacity <= options->ops.num_operations) {
unsigned original_capacity = options->ops.capacity;
options->ops.capacity *= 4;
- if(0 == (options->ops.operations = realloc(options->ops.operations, sizeof(Operation) * options->ops.capacity)))
+ if(0 == (options->ops.operations = (Operation*)realloc(options->ops.operations, sizeof(Operation) * options->ops.capacity)))
die("out of memory allocating space for option list");
memset(options->ops.operations + original_capacity, 0, sizeof(Operation) * (options->ops.capacity - original_capacity));
}
@@ -674,14 +674,14 @@ void append_new_argument(CommandLineOptions *options, Argument argument)
{
if(options->args.capacity == 0) {
options->args.capacity = 50;
- if(0 == (options->args.arguments = malloc(sizeof(Argument) * options->args.capacity)))
+ if(0 == (options->args.arguments = (Argument*)malloc(sizeof(Argument) * options->args.capacity)))
die("out of memory allocating space for option list");
memset(options->args.arguments, 0, sizeof(Argument) * options->args.capacity);
}
if(options->args.capacity <= options->args.num_arguments) {
unsigned original_capacity = options->args.capacity;
options->args.capacity *= 4;
- if(0 == (options->args.arguments = realloc(options->args.arguments, sizeof(Argument) * options->args.capacity)))
+ if(0 == (options->args.arguments = (Argument*)realloc(options->args.arguments, sizeof(Argument) * options->args.capacity)))
die("out of memory allocating space for option list");
memset(options->args.arguments + original_capacity, 0, sizeof(Argument) * (options->args.capacity - original_capacity));
}
@@ -897,7 +897,7 @@ FLAC__bool parse_block_number(const char *in, Argument_BlockNumber *out)
/* make space */
FLAC__ASSERT(out->num_entries > 0);
- if(0 == (out->entries = malloc(sizeof(unsigned) * out->num_entries)))
+ if(0 == (out->entries = (unsigned*)malloc(sizeof(unsigned) * out->num_entries)))
die("out of memory allocating space for option list");
/* load 'em up */
@@ -936,7 +936,7 @@ FLAC__bool parse_block_type(const char *in, Argument_BlockType *out)
/* make space */
FLAC__ASSERT(out->num_entries > 0);
- if(0 == (out->entries = malloc(sizeof(Argument_BlockTypeEntry) * out->num_entries)))
+ if(0 == (out->entries = (Argument_BlockTypeEntry*)malloc(sizeof(Argument_BlockTypeEntry) * out->num_entries)))
die("out of memory allocating space for option list");
/* load 'em up */
diff --git a/src/metaflac/usage.c b/src/metaflac/usage.c
index 0b067a2b..6fab15db 100644
--- a/src/metaflac/usage.c
+++ b/src/metaflac/usage.c
@@ -57,7 +57,7 @@ static void usage_summary(FILE *out)
fprintf(out, " (the default if more than one FLAC file is specified)\n");
fprintf(out, "--no-filename Do not prefix each output line with the FLAC file name\n");
fprintf(out, " (the default if only one FLAC file is specified)\n");
- fprintf(out, "--no-utf8-convert Do not convert Vorbis comments from UTF-8 to local charset,\n");
+ fprintf(out, "--no-utf8-convert Do not convert tags from UTF-8 to local charset,\n");
fprintf(out, " or vice versa. This is useful for scripts.\n");
fprintf(out, "--dont-use-padding By default metaflac tries to use padding where possible\n");
fprintf(out, " to avoid rewriting the entire file if the metadata size\n");
@@ -130,12 +130,12 @@ int long_usage(const char *message, ...)
fprintf(out, "--export-tags-to=FILE Export tags to a file. Use '-' for stdin. Each line\n");
fprintf(out, " will be of the form NAME=VALUE. Specify\n");
fprintf(out, " --no-utf8-convert if necessary.\n");
- fprintf(out, "--import-cuesheet-from=FILE Import a cuesheet from a file. Only one FLAC\n");
- fprintf(out, " file may be specified. A seekpoint will be added for\n");
- fprintf(out, " each index point in the cuesheet to the SEEKTABLE unless\n");
- fprintf(out, " --no-cued-seekpoints is specified.\n");
+ fprintf(out, "--import-cuesheet-from=FILE Import a cuesheet from a file. Use '-' for stdin.\n");
+ fprintf(out, " Only one FLAC file may be specified. A seekpoint will be\n");
+ fprintf(out, " added for each index point in the cuesheet to the SEEKTABLE\n");
+ fprintf(out, " unless --no-cued-seekpoints is specified.\n");
fprintf(out, "--export-cuesheet-to=FILE Export CUESHEET block to a cuesheet file, suitable\n");
- fprintf(out, " for use by CD authoring software. Use '-' for stdin.\n");
+ fprintf(out, " for use by CD authoring software. Use '-' for stdout.\n");
fprintf(out, " Only one FLAC file may be specified on the command line.\n");
fprintf(out, "--add-replay-gain Calculates the title and album gains/peaks of the given\n");
fprintf(out, " FLAC files as if all the files were part of one album,\n");
@@ -180,7 +180,7 @@ int long_usage(const char *message, ...)
fprintf(out, "\n");
fprintf(out, " --block-type=type[,type[...]]\n");
fprintf(out, " --except-block-type=type[,type[...]]\n");
- fprintf(out, " An optional comma-separated list of block types to included or ignored\n");
+ fprintf(out, " An optional comma-separated list of block types to be included or ignored\n");
fprintf(out, " with this option. Use only one of --block-type or --except-block-type.\n");
fprintf(out, " The valid block types are: STREAMINFO, PADDING, APPLICATION, SEEKTABLE,\n");
fprintf(out, " VORBIS_COMMENT. You may narrow down the types of APPLICATION blocks\n");
diff --git a/src/metaflac/utils.c b/src/metaflac/utils.c
index 745e70f4..ee9d03ba 100644
--- a/src/metaflac/utils.c
+++ b/src/metaflac/utils.c
@@ -64,7 +64,7 @@ void local_strcat(char **dest, const char *source)
if(nsource == 0)
return;
- *dest = realloc(*dest, ndest + nsource + 1);
+ *dest = (char*)realloc(*dest, ndest + nsource + 1);
if(0 == *dest)
die("out of memory growing string");
strcpy((*dest)+ndest, source);