Prepends our settings to the user's `GODEBUG`. Go uses the last occurrence of a setting, so an explicit `randautoseed` from the user still wins.
(user_godebug: Option<&str>)
| 12 | /// Prepends our settings to the user's `GODEBUG`. Go uses the last occurrence |
| 13 | /// of a setting, so an explicit `randautoseed` from the user still wins. |
| 14 | fn godebug(user_godebug: Option<&str>) -> String { |
| 15 | match user_godebug { |
| 16 | Some(user) if !user.is_empty() => format!("{RANDAUTOSEED_OFF},{user}"), |
| 17 | _ => RANDAUTOSEED_OFF.to_owned(), |
| 18 | } |
| 19 | } |
| 20 | |
| 21 | #[cfg(test)] |
| 22 | mod tests { |