title: How to programmatically clear android logcat log from application
body: <p>Is there a way to clear android logcat from the application itself.</p>
  
  <p>I'm able to read logcat within the app using;</p>
  
  <pre><code>Process process = Runtime.getRuntime().exec("logcat -d -v long");
  
  BufferedReader bufferedReader = new BufferedReader(
      new InputStreamReader(process.getInputStream()));
  </code></pre>
  
  <p>but using </p>
  
  <pre><code>Process process = Runtime.getRuntime().exec("logcat -c");
  </code></pre>
  
  <p>and the re-reading with the above read method it's not possible to clear the log. It's just getting the same log again.</p>
  
  <p>This however works within android emulator but not in actual device.</p>