We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f3d40e8 commit a8a437aCopy full SHA for a8a437a
1 file changed
src/auth/token_store.rs
@@ -158,12 +158,15 @@ fn keyring_disabled() -> bool {
158
.is_some_and(|value| matches!(value.as_str(), "1" | "true" | "TRUE" | "yes" | "YES"))
159
}
160
161
+#[cfg(unix)]
162
fn set_private_permissions(path: &std::path::Path) -> Result<()> {
- #[cfg(unix)]
163
- {
164
- use std::os::unix::fs::PermissionsExt;
165
- std::fs::set_permissions(path, std::fs::Permissions::from_mode(0o600))?;
166
- }
+ use std::os::unix::fs::PermissionsExt;
+ std::fs::set_permissions(path, std::fs::Permissions::from_mode(0o600))?;
+ Ok(())
+}
167
+
168
+#[cfg(not(unix))]
169
+fn set_private_permissions(_path: &std::path::Path) -> Result<()> {
170
Ok(())
171
172
0 commit comments