Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
J
jami-daemon
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
130
Issues
130
List
Boards
Labels
Service Desk
Milestones
Iterations
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Analytics
Analytics
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
savoirfairelinux
jami-daemon
Commits
f7fe93d1
Commit
f7fe93d1
authored
Apr 27, 2015
by
Adrien Béraud
Committed by
Gerrit Code Review
Apr 27, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pulseaudio: fix memory corruption
Refs #71680 Change-Id: Ibe64bc2fa323c589c2323d2bea4a80269a2a84e0
parent
4e8c7f32
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
src/media/audio/pulseaudio/pulselayer.cpp
src/media/audio/pulseaudio/pulselayer.cpp
+3
-2
No files found.
src/media/audio/pulseaudio/pulselayer.cpp
View file @
f7fe93d1
...
...
@@ -468,7 +468,7 @@ void PulseLayer::writeToSpeaker()
pa_stream
*
s
=
playback_
->
pulseStream
();
const
pa_sample_spec
*
sample_spec
=
pa_stream_get_sample_spec
(
s
);
size_t
sample_size
=
pa_frame_size
(
sample_spec
);
const
AudioFormat
format
(
playback_
->
getFormat
()
);
const
AudioFormat
format
(
sample_spec
->
rate
,
sample_spec
->
channels
);
// available bytes to be written in pulseaudio internal buffer
int
ret
=
pa_stream_writable_size
(
s
);
...
...
@@ -554,9 +554,10 @@ void PulseLayer::writeToSpeaker()
pa_stream_begin_write
(
s
,
(
void
**
)
&
data
,
&
resampledBytes
);
playbackBuffer_
.
setFormat
(
f
ormat
);
playbackBuffer_
.
setFormat
(
mainBufferAudioF
ormat
);
playbackBuffer_
.
resize
(
readableSamples
);
Manager
::
instance
().
getRingBufferPool
().
getData
(
playbackBuffer_
,
RingBufferPool
::
DEFAULT_ID
);
playbackBuffer_
.
setChannelNum
(
format
.
nb_channels
,
true
);
if
(
resample
)
{
AudioBuffer
rsmpl_out
(
nResampled
,
format
);
...
...
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