Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
fdk-aac
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
fdk-aac
Commits
3951d0a4
Commit
3951d0a4
authored
Feb 07, 2014
by
Martin Storsjo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow opening stdin when "-" is specified
parent
e7348e7a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
wavreader.c
wavreader.c
+6
-2
No files found.
wavreader.c
View file @
3951d0a4
...
...
@@ -68,7 +68,10 @@ void* wav_read_open(const char *filename) {
long
data_pos
=
0
;
memset
(
wr
,
0
,
sizeof
(
*
wr
));
wr
->
wav
=
fopen
(
filename
,
"rb"
);
if
(
!
strcmp
(
filename
,
"-"
))
wr
->
wav
=
stdin
;
else
wr
->
wav
=
fopen
(
filename
,
"rb"
);
if
(
wr
->
wav
==
NULL
)
{
free
(
wr
);
return
NULL
;
...
...
@@ -136,7 +139,8 @@ void* wav_read_open(const char *filename) {
void
wav_read_close
(
void
*
obj
)
{
struct
wav_reader
*
wr
=
(
struct
wav_reader
*
)
obj
;
fclose
(
wr
->
wav
);
if
(
wr
->
wav
!=
stdin
)
fclose
(
wr
->
wav
);
free
(
wr
);
}
...
...
Write
Preview
Markdown
is supported
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