AI 143785: am: CL 143775 am: CL 143620 Attempt for fixing crash in AudioFlinger::MixerThread::dumpTracks() seen in bug report for issue 1747119.
  AudioFlinger::MixerThread::dumpTracks() was reading mTracks[] vector instead of mActiveTracks[] when dumping active tracks.
  Original author: elaurent
  Merged from: //branches/cupcake/...
  Original author: android-build
  Merged from: //branches/donutburger/...

Automated import of CL 143785
diff --git a/libs/audioflinger/AudioFlinger.cpp b/libs/audioflinger/AudioFlinger.cpp
index b9ecdd8..d11e13a 100644
--- a/libs/audioflinger/AudioFlinger.cpp
+++ b/libs/audioflinger/AudioFlinger.cpp
@@ -941,13 +941,10 @@
     result.append(buffer);
     result.append("   Name Clien Typ Fmt Chn Buf S M F SRate LeftV RighV Serv User\n");
     for (size_t i = 0; i < mTracks.size(); ++i) {
-        wp<Track> wTrack = mTracks[i];
-        if (wTrack != 0) {
-            sp<Track> track = wTrack.promote();
-            if (track != 0) {
-                track->dump(buffer, SIZE);
-                result.append(buffer);
-            }
+        sp<Track> track = mTracks[i];
+        if (track != 0) {
+            track->dump(buffer, SIZE);
+            result.append(buffer);
         }
     }
 
@@ -955,7 +952,7 @@
     result.append(buffer);
     result.append("   Name Clien Typ Fmt Chn Buf S M F SRate LeftV RighV Serv User\n");
     for (size_t i = 0; i < mActiveTracks.size(); ++i) {
-        wp<Track> wTrack = mTracks[i];
+        wp<Track> wTrack = mActiveTracks[i];
         if (wTrack != 0) {
             sp<Track> track = wTrack.promote();
             if (track != 0) {