title: Android M Permissions: onRequestPermissionsResult() not being called
body: <p>I'm updating our app to use the new M runtime permissions system.
  It's all working except for onRequestPermissionsResult(). I need to check a permission on a button press, and if it's successful, send a text message. When I grant permission to do it, the dialog closes, but it doesn't trigger the Send Text until I press the button again.</p>
  
  <p>I've debugged and set breakpoints in the onRequestPermissionsResult() method but it never goes into it.</p>
  
  <p>This method gets called first:</p>
  
  <pre><code>    private void askForPermission() {
      String[] permissions = new String[]{Manifest.permission.SEND_SMS};
      ActivityCompat.requestPermissions(getActivity(), permissions, PERMISSIONS_CODE);
  }
  </code></pre>
  
  <p>And then my callback looks like this:</p>
  
  <pre><code>    @Override
  public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) {
      super.onRequestPermissionsResult(requestCode, permissions, grantResults);
  
      if (requestCode == PERMISSIONS_CODE) {
          for (int i = 0; i &lt; permissions.length; i++) {
              String permission = permissions[i];
              int grantResult = grantResults[i];
  
              if (permission.equals(Manifest.permission.SEND_SMS)) {
                  if (grantResult == PackageManager.PERMISSION_GRANTED) {
                      onPPSButtonPress();
                  } else {
                      requestPermissions(new String[]{Manifest.permission.SEND_SMS}, PERMISSIONS_CODE);
                  }
              }
          }
      }
  }
  </code></pre>
  
  <p>Has anybody run into a similar issue?
  Appreciate any help with this.
  Thanks</p>