title: Android superuser shutdown/reboot commands not doing anything
body: <p>I am trying to make an app that can shutdown/reboot your phone at the touch of a button. I found a command online for reboot:</p>
  
  <pre><code>public void rebootPhone() {
      try {
          Runtime.getRuntime().exec("su");
          Runtime.getRuntime().exec("reboot");
      } catch (IOException e) {
          // TODO Auto-generated catch block
          e.printStackTrace();
      }
  }
  </code></pre>
  
  <p>I understand this requires root (for the "su" superuser command); My phone has been rooted so I can gain su access. However when this method is run (after I press 'yes' on the prompt to allow su access) the phone does not reboot, nothing happens! Is there something else i need to include to make the phone reboot? </p>
  
  <p>Also, what is the su command for shutdown (i.e. to just turn your phone off)? I can't find it anywhere on the net.</p>