Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Xiph.Org
flac
Commits
bef021a1
Commit
bef021a1
authored
Sep 03, 2003
by
Josh Coalson
Browse files
fix possibly uninitialized var if a file has no STREAMINFO block
parent
9bb1a16f
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/metaflac/operations_shorthand_cuesheet.c
View file @
bef021a1
...
...
@@ -30,7 +30,7 @@ FLAC__bool do_shorthand_operation__cuesheet(const char *filename, FLAC__Metadata
FLAC__bool
ok
=
true
;
FLAC__StreamMetadata
*
cuesheet
=
0
;
FLAC__Metadata_Iterator
*
iterator
=
FLAC__metadata_iterator_new
();
FLAC__uint64
lead_out_offset
;
FLAC__uint64
lead_out_offset
=
0
;
if
(
0
==
iterator
)
die
(
"out of memory allocating iterator"
);
...
...
@@ -56,6 +56,12 @@ FLAC__bool do_shorthand_operation__cuesheet(const char *filename, FLAC__Metadata
cuesheet
=
block
;
}
while
(
FLAC__metadata_iterator_next
(
iterator
));
if
(
lead_out_offset
==
0
)
{
fprintf
(
stderr
,
"%s: ERROR: FLAC stream has no STREAMINFO block
\n
"
,
filename
);
FLAC__metadata_iterator_delete
(
iterator
);
return
false
;
}
switch
(
operation
->
type
)
{
case
OP__IMPORT_CUESHEET_FROM
:
if
(
0
!=
cuesheet
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment