From a64a36e2805c966b3237969a222011290d0b6a31 Mon Sep 17 00:00:00 2001 From: Ed Maste Date: Mon, 31 Aug 2015 12:28:13 +0000 Subject: [PATCH] ar: fix deterministic mode when running as ranlib This was broken by r286024. PR: 202741 Submitted by: fk@fabiankeil.de Obtained from: ElectroBSD --- usr.bin/ar/ar.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/usr.bin/ar/ar.c b/usr.bin/ar/ar.c index 4dee029b96aa..9bc70de4ff45 100644 --- a/usr.bin/ar/ar.c +++ b/usr.bin/ar/ar.c @@ -144,6 +144,9 @@ main(int argc, char **argv) if (*argv == NULL) ranlib_usage(); + /* Enable determinstic mode unless -U is set. */ + if (Uflag == 0) + bsdar->options |= AR_D; bsdar->options |= AR_S; for (;(bsdar->filename = *argv++) != NULL;) ar_mode_s(bsdar);