Deprecate AudioRecord::getInput() and AudioTrack::getOutput()

Does not completely fix the bug, but is a step in the right direction.

Bug: 12593118
Change-Id: Id591cd700ab58fd927ae44c71c81dac55b5cac2d
diff --git a/include/media/AudioRecord.h b/include/media/AudioRecord.h
index 52d798e..e4c98fb 100644
--- a/include/media/AudioRecord.h
+++ b/include/media/AudioRecord.h
@@ -315,7 +315,12 @@
      * Returned value:
      *  handle on audio hardware input
      */
-            audio_io_handle_t    getInput() const;
+// FIXME The only known public caller is frameworks/opt/net/voip/src/jni/rtp/AudioGroup.cpp
+            audio_io_handle_t    getInput() const __attribute__((__deprecated__))
+                                                { return getInputPrivate(); }
+private:
+            audio_io_handle_t    getInputPrivate() const;
+public:
 
     /* Returns the audio session ID associated with this AudioRecord.
      *
diff --git a/include/media/AudioTrack.h b/include/media/AudioTrack.h
index fd9200a..2b605cc 100644
--- a/include/media/AudioTrack.h
+++ b/include/media/AudioTrack.h
@@ -465,7 +465,9 @@
      *  handle on audio hardware output, or AUDIO_IO_HANDLE_NONE if the
      *  track needed to be re-created but that failed
      */
+private:
             audio_io_handle_t    getOutput() const;
+public:
 
     /* Returns the unique session ID associated with this track.
      *
diff --git a/media/libmedia/AudioRecord.cpp b/media/libmedia/AudioRecord.cpp
index eb9f1f0..55a448e 100644
--- a/media/libmedia/AudioRecord.cpp
+++ b/media/libmedia/AudioRecord.cpp
@@ -416,7 +416,7 @@
 uint32_t AudioRecord::getInputFramesLost() const
 {
     // no need to check mActive, because if inactive this will return 0, which is what we want
-    return AudioSystem::getInputFramesLost(getInput());
+    return AudioSystem::getInputFramesLost(getInputPrivate());
 }
 
 // -------------------------------------------------------------------------
@@ -712,7 +712,7 @@
     // the server does not automatically disable recorder on overrun, so no need to restart
 }
 
-audio_io_handle_t AudioRecord::getInput() const
+audio_io_handle_t AudioRecord::getInputPrivate() const
 {
     AutoMutex lock(mLock);
     return mInput;