M src/system.rs => src/system.rs +2 -2
@@ 31,8 31,8 @@ pub fn drop_privileges(user: &User) -> Result<()> {
Ok(())
}
-/// Reads environment variable `$XDG_RUNTIME_DIR` (or sets it to `/run/user/$UID`) and
-/// ensures a directory with the correct perms exists at the path.
+/// Reads environment variable `$XDG_RUNTIME_DIR` and ensures a directory with
+/// the correct perms exists at the path.
///
/// Requires root.
pub fn prepare_xdg_runtime(user: &User) -> Result<()> {
M src/user.rs => src/user.rs +2 -1
@@ 56,7 56,8 @@ impl User {
/// Loads the user's environment by executing `env` through a login shell.
///
/// The [return value](xdg::BaseDirectories) is useful for later functions to determine
- /// runtime, state, and cache storage.
+ /// runtime, state, and cache storage. Accordingly, the env var `$XDG_RUNTIME_DIR`
+ /// will default to `/run/user/$UID` if unset.
///
/// Known to work with: bash, dash, and zsh.
pub fn load_environment(&self) -> Result<BaseDirectories> {