Repository navigation
google-http-client-android 1.31+ Posix crash #906
Copy link
Copy link
Closed
Labels
🚨This issue needs some love.This issue needs some love.priority: p2Moderately-important priority. Fix may not be included in next release.Moderately-important priority. Fix may not be included in next release.semver: patchA minor bug fix or small change.A minor bug fix or small change.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Description
Activity
- addedtriage meI really want to be triaged.I really want to be triaged.
on Dec 8, 2019 - addedtype: docsImprovement to the documentation for an API.Improvement to the documentation for an API.
on Dec 9, 2019 - removedtriage meI really want to be triaged.I really want to be triaged.
on Dec 10, 2019 - addedsemver: patchA minor bug fix or small change.A minor bug fix or small change.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.and removedtype: docsImprovement to the documentation for an API.Improvement to the documentation for an API.
on Mar 13, 2020 This is the code. It probably needs to catch
LinkageErrortoo and possibly use reflection:static void setPermissionsToOwnerOnly(File file) throws IOException { Set permissions = new HashSet<PosixFilePermission>(); permissions.add(PosixFilePermission.OWNER_READ); permissions.add(PosixFilePermission.OWNER_WRITE); permissions.add(PosixFilePermission.OWNER_EXECUTE); try { Files.setPosixFilePermissions(Paths.get(file.getAbsolutePath()), permissions); } catch (UnsupportedOperationException exception) { LOGGER.warning("Unable to set permissions for " + file + ", because you are running on a non-POSIX file system."); } catch (SecurityException exception) { // ignored } catch (IllegalArgumentException exception) { // ignored } }Reacted by Adrian Crețu- added🚨This issue needs some love.This issue needs some love.triage meI really want to be triaged.I really want to be triaged.
on Mar 13, 2020 - addedpriority: p2Moderately-important priority. Fix may not be included in next release.Moderately-important priority. Fix may not be included in next release.
on Mar 16, 2020 - removed🚨This issue needs some love.This issue needs some love.triage meI really want to be triaged.I really want to be triaged.
on Mar 16, 2020
Metadata
Metadata
Assignees
Labels
🚨This issue needs some love.This issue needs some love.priority: p2Moderately-important priority. Fix may not be included in next release.Moderately-important priority. Fix may not be included in next release.semver: patchA minor bug fix or small change.A minor bug fix or small change.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
uses
PosixFilePermissionThis class was added only in Android API 26. Running on lower API devices results in:
Crash happens when trying to store OAuth credentials and doing something trivial like
Maybe since the package releases as "Android-compatible" this should be documented?