First, clear an issue which was causing an assert to fire. Basically,
once a decoder pump had entered the error state and was shutdown, it
was not clearing its status, and when a substream attempt to recycle
the pump, startup was failing an assert (no thread had been created,
meaning that the system was not initialized, yet status indicated an
error). This was a small one-liner in aah_decoder_pump.cpp.
Second, try to become a little nuanced about how we handle errors in
the decoder pump. A comment in the code pretty much says it all, but
the summary is that we don't want to completely abort playback because
a single chunk of ES failed to decode, but if nothing is decoding and
we are making no progress at all, we probably need to put the
MediaPlayer instance into the fatal Error state and signal the app
level so that further action can be taken (automatic recovery attempts
followed by bug reports and signalling the user if those fail).
This is to address the fallout of http://b/issue?id=5498460, where
something at the OMX decoder level becomes unhappy about not being
able to obtain an output buffer which eventually unwinds to this
assert which results in a dead mediaserver. After this change, the
mediaserver will no longer crash, and may even recover (depending on
whether or not the OMX unhappiness is transient or not), but the
primary issue (unhappy OMX) is probably still around. It is quite
difficult to reproduce, I will probably need to open a different bug
to track that issue.
Change-Id: I5b65b818378a5ae9c915e91b7db7129f0bda6837
Signed-off-by: John Grossman <johngro@google.com>
Make the standby time for AudioFlinger configurable using a system
property. Default AudioFlinger behavior is to go into standby
(allowing the audio outputs to underflow) after there has been nothing
to mix and AudioFlinger has just been pumping out silence for the
configured standby time (which defaulted to 3 seconds).
Now, by setting the "ro.audio.flinger_standbytime_ms" property in
their platform init.rc, platforms can override this default and
control the standby time. If the property is missing or malformed,
the old default value of 3 seconds will be used instead.
Change-Id: Ic9fa8b5f5bccee493bc72c65e408d3fd8ddd1059
Signed-off-by: John Grossman <johngro@google.com>
Ensure log_clusters array is big enough.
Bug: 5714171
Explicitly handle the cases where the entire string or a single
run might have a length of 0.
Harfbuzz assumes the length of the item is at least 1.
If the length is zero, then it will clobber memory at index -1
into the log_clusters array.
Bug: 5705479
Change-Id: If28a9866221081f69973c1d12d7fe0cf8db2edd0
New API to let you build an Intent whose base configuration is correct,
but has an additional "selector" to pick out the specific app that you
would like launched.
Change-Id: Ide9db6dc60e2844b7696cfe09b28337fe7dd63db
Move broadcastState(BluetoothAdapter.STATE_TURNING_ON/OFF) before any other
method calls when turn on/off Bluetooth.
Bug 5703346
Change-Id: Iddbdab58367a7d648708aa23671eb09701d66793
* commit 'b5f2dfbc221d3dc799232e0ada3b6621d3d4d597':
By default ICS allows two syncs to run in parallel. Make it only do one at a time for devices that don't have much RAM as defined by the call ActivityManager.isLargeRAM()
do one at a time for devices that don't have much RAM as
defined by the call ActivityManager.isLargeRAM()
Bug: 5713224
Change-Id: Ic8c42103f4031e1d7b1db797edcbbd7f7bac1387