diff options
author | Paul Smith <psmith@gnu.org> | 2022-10-15 18:11:21 -0400 |
---|---|---|
committer | Paul Smith <psmith@gnu.org> | 2022-10-16 16:18:21 -0400 |
commit | e5e538fb7a9cb6a42dae6aa1ad9f36a3dc769ad9 (patch) | |
tree | de826cb70346fcdc802278f177da8a671c25b071 /src/main.c | |
parent | c453f898a00db16e3fc3648ffd65fcf3a23dc806 (diff) | |
download | make-git-e5e538fb7a9cb6a42dae6aa1ad9f36a3dc769ad9.tar.gz |
[SV 63215] Remember the random seed for shuffle mode
Basic fix provided by James Hilliard <james.hilliard1@gmail.com>.
Ensure we remember and propagate the random seed we generate during
shuffle mode. Also add a debug statement displaying the seed.
* src/shuffle.c (shuffle_set_mode): Init and save the randoms seed.
* src/misc.c (make_rand): Code cleanups.
* src/main.c (main): Show a debug message containing the seed.
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -2318,6 +2318,9 @@ main (int argc, char **argv, char **envp) OUTPUT_UNSET (); output_close (&make_sync); + if (shuffle_mode) + DB (DB_BASIC, (_("Enabled shuffle mode: %s\n"), shuffle_mode)); + if (read_files) { /* Update any makefiles if necessary. */ |