Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
miniaudio
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
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
MyCard
miniaudio
Commits
b2b20ee1
Commit
b2b20ee1
authored
Mar 11, 2018
by
David Reid
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix a few bugs found through static analysis.
parent
afb0029d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
mini_al.h
mini_al.h
+4
-4
No files found.
mini_al.h
View file @
b2b20ee1
...
...
@@ -3237,7 +3237,7 @@ static mal_result mal_context__try_get_device_name_by_id(mal_context* pContext,
#ifdef MAL_HAS_WASAPI
case
mal_backend_wasapi
:
{
if
(
memcmp
(
pDeviceID
->
wasapi
,
&
pInfos
[
iDevice
].
id
.
wasapi
,
sizeof
(
pDeviceID
->
wasapi
))
==
0
)
{
if
(
memcmp
(
pDeviceID
->
wasapi
,
pInfos
[
iDevice
].
id
.
wasapi
,
sizeof
(
pDeviceID
->
wasapi
))
==
0
)
{
found
=
MAL_TRUE
;
}
}
break
;
...
...
@@ -3245,7 +3245,7 @@ static mal_result mal_context__try_get_device_name_by_id(mal_context* pContext,
#ifdef MAL_HAS_DSOUND
case
mal_backend_dsound
:
{
if
(
memcmp
(
pDeviceID
->
dsound
,
&
pInfos
[
iDevice
].
id
.
dsound
,
sizeof
(
pDeviceID
->
dsound
))
==
0
)
{
if
(
memcmp
(
pDeviceID
->
dsound
,
pInfos
[
iDevice
].
id
.
dsound
,
sizeof
(
pDeviceID
->
dsound
))
==
0
)
{
found
=
MAL_TRUE
;
}
}
break
;
...
...
@@ -4103,7 +4103,7 @@ static mal_result mal_enumerate_devices__wasapi(mal_context* pContext, mal_devic
hr
=
IMMDevice_GetId
(
pDevice
,
&
id
);
if
(
SUCCEEDED
(
hr
))
{
size_t
idlen
=
wcslen
(
id
);
if
(
idlen
+
sizeof
(
wchar_t
)
>
size
of
(
pInfo
->
id
.
wasapi
))
{
if
(
idlen
+
1
>
mal_count
of
(
pInfo
->
id
.
wasapi
))
{
mal_CoTaskMemFree
(
pContext
,
id
);
mal_assert
(
MAL_FALSE
);
// NOTE: If this is triggered, please report it. It means the format of the ID must haved change and is too long to fit in our fixed sized buffer.
continue
;
...
...
@@ -14542,7 +14542,7 @@ mal_dsp_config mal_dsp_config_init_ex(mal_format formatIn, mal_uint32 channelsIn
mal_copy_memory
(
config
.
channelMapIn
,
channelMapIn
,
sizeof
(
config
.
channelMapIn
));
}
if
(
channelMapOut
!=
NULL
)
{
mal_copy_memory
(
config
.
channelMap
In
,
channelMapIn
,
sizeof
(
config
.
channelMapIn
));
mal_copy_memory
(
config
.
channelMap
Out
,
channelMapOut
,
sizeof
(
config
.
channelMapOut
));
}
return
config
;
...
...
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