Skip to content

Commit

Permalink
#141 - Release unused SAF persistable permission
Browse files Browse the repository at this point in the history
  • Loading branch information
GrazianoCapelli committed Nov 21, 2021
1 parent f654004 commit ad6316e
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1669,6 +1669,9 @@ public boolean isExportFolderWritable() {
Log.w("myApp", "[#] GPSApplication.java - IllegalArgumentException - isExportFolderWritable = FALSE: " + item.getUri());
}
}
// Releases the unused persistable permission
getApplicationContext().getContentResolver().releasePersistableUriPermission(item.getUri(),
Intent.FLAG_GRANT_READ_URI_PERMISSION | Intent.FLAG_GRANT_WRITE_URI_PERMISSION);
}
Log.w("myApp", "[#] GPSApplication.java - isExportFolderWritable = FALSE");
return false;
Expand Down

0 comments on commit ad6316e

Please sign in to comment.