From 529798f31b2b7dccb5b8955d05093124e8e43d2a Mon Sep 17 00:00:00 2001 From: Tobias Stoeckmann Date: Sun, 11 Nov 2007 09:51:50 +0000 Subject: If a file has modifications in it (i.e. cvs update on modified files), reapply umask as done with unmodified files. Sticks at GNU cvs behaviour. --- usr.bin/cvs/client.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'usr.bin/cvs') diff --git a/usr.bin/cvs/client.c b/usr.bin/cvs/client.c index 701ecefa7a7..f5904142526 100644 --- a/usr.bin/cvs/client.c +++ b/usr.bin/cvs/client.c @@ -1,4 +1,4 @@ -/* $OpenBSD: client.c,v 1.82 2007/10/07 18:12:48 chl Exp $ */ +/* $OpenBSD: client.c,v 1.83 2007/11/11 09:51:49 tobias Exp $ */ /* * Copyright (c) 2006 Joris Vink * @@ -725,7 +725,7 @@ cvs_client_merged(char *data) { int fd; time_t now; - mode_t fmode; + mode_t fmode, mask; size_t flen; CVSENTRIES *ent; const char *errstr; @@ -763,6 +763,9 @@ cvs_client_merged(char *data) cvs_strtomode(mode, &fmode); xfree(mode); + mask = umask(0); + umask(mask); + fmode &= ~mask; time(&now); asctime_r(gmtime(&now), timebuf); -- cgit v1.2.3