diff options
| author | Junio C Hamano <gitster@pobox.com> | 2023-08-24 09:32:34 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2023-08-24 09:32:34 -0700 |
| commit | c7b6a6c0be7cdc847eb6e0f0e8a636b8c79fd480 (patch) | |
| tree | 669902b63d2a2e8564f69e3f5a2402182724a7b1 /wrapper.c | |
| parent | 004a3830918a2b20e53ad817a68e75f46c3fe41a (diff) | |
| parent | 69ecfcacfd136810f2343b548174efe9ae3fdead (diff) | |
| download | git-c7b6a6c0be7cdc847eb6e0f0e8a636b8c79fd480.tar.xz | |
Merge branch 'ds/maintenance-schedule-fuzz'
Hourly and other schedule of "git maintenance" jobs are randomly
distributed now.
* ds/maintenance-schedule-fuzz:
maintenance: update schedule before config
maintenance: fix systemd schedule overlaps
maintenance: use random minute in systemd scheduler
maintenance: swap method locations
maintenance: use random minute in cron scheduler
maintenance: use random minute in Windows scheduler
maintenance: use random minute in launchctl scheduler
maintenance: add get_random_minute()
Diffstat (limited to 'wrapper.c')
| -rw-r--r-- | wrapper.c | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -819,3 +819,13 @@ int csprng_bytes(void *buf, size_t len) return 0; #endif } + +uint32_t git_rand(void) +{ + uint32_t result; + + if (csprng_bytes(&result, sizeof(result)) < 0) + die(_("unable to get random bytes")); + + return result; +} |
