OpenBSD CVS

CVS log for src/usr.bin/chpass/edit.c


[BACK] Up to [local] / src / usr.bin / chpass

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.36 / (download) - annotate - [select for diffs], Fri Aug 11 04:45:05 2023 UTC (9 months, 1 week ago) by guenther
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, HEAD
Changes since 1.35: +2 -2 lines
Diff to previous 1.35 (colored)

Replace use of the old BSD st_*timespec members in struct stat with
the POSIX-standard st_*tim members.

ok millert@

Revision 1.35 / (download) - annotate - [select for diffs], Fri Jan 16 06:40:06 2015 UTC (9 years, 4 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8, OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5, OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2, OPENBSD_6_1_BASE, OPENBSD_6_1, OPENBSD_6_0_BASE, OPENBSD_6_0, OPENBSD_5_9_BASE, OPENBSD_5_9, OPENBSD_5_8_BASE, OPENBSD_5_8, OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.34: +2 -2 lines
Diff to previous 1.34 (colored)

Replace <sys/param.h> with <limits.h> and other less dirty headers where
possible.  Annotate <sys/param.h> lines with their current reasons.  Switch
to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc.  Change
MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where
sensible to avoid pulling in the pollution.  These are the files confirmed
through binary verification.
ok guenther, millert, doug (helped with the verification protocol)

Revision 1.34 / (download) - annotate - [select for diffs], Tue Nov 26 13:18:55 2013 UTC (10 years, 5 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6, OPENBSD_5_5_BASE, OPENBSD_5_5
Changes since 1.33: +4 -3 lines
Diff to previous 1.33 (colored)

unsigned char casts for ctype
ok krw

Revision 1.33 / (download) - annotate - [select for diffs], Tue Oct 27 23:59:36 2009 UTC (14 years, 6 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3, OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0, OPENBSD_4_9_BASE, OPENBSD_4_9, OPENBSD_4_8_BASE, OPENBSD_4_8, OPENBSD_4_7_BASE, OPENBSD_4_7
Changes since 1.32: +1 -9 lines
Diff to previous 1.32 (colored)

rcsid[] and sccsid[] and copyright[] are essentially unmaintained (and
unmaintainable).  these days, people use source.  these id's do not provide
any benefit, and do hurt the small install media
(the 33,000 line diff is essentially mechanical)
ok with the idea millert, ok dms

Revision 1.32 / (download) - annotate - [select for diffs], Thu Mar 5 20:53:13 2009 UTC (15 years, 2 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.31: +3 -3 lines
Diff to previous 1.31 (colored)

Call endusershell() at the end of ok_shell(), making a copy of the
(possibly) expanded shell as needed.  OK deraadt@

Revision 1.31 / (download) - annotate - [select for diffs], Sat Nov 17 16:47:21 2007 UTC (16 years, 6 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_4_5_BASE, OPENBSD_4_5, OPENBSD_4_4_BASE, OPENBSD_4_4, OPENBSD_4_3_BASE, OPENBSD_4_3
Changes since 1.30: +3 -3 lines
Diff to previous 1.30 (colored)

Use mtimespec instead of mtime when comparing the timestamp of the edited
file.  OK miod@

Revision 1.30 / (download) - annotate - [select for diffs], Tue Mar 20 03:50:38 2007 UTC (17 years, 2 months ago) by tedu
Branch: MAIN
CVS Tags: OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.29: +3 -3 lines
Diff to previous 1.29 (colored)

remove some bogus *p tests from charles longeau
ok deraadt millert

Revision 1.29 / (download) - annotate - [select for diffs], Thu Mar 30 21:08:21 2006 UTC (18 years, 1 month ago) by robert
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_1, OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.28: +4 -3 lines
Diff to previous 1.28 (colored)

use size_t where needed; ok deraadt@

Revision 1.28 / (download) - annotate - [select for diffs], Mon Nov 14 15:31:11 2005 UTC (18 years, 6 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9
Changes since 1.27: +8 -18 lines
Diff to previous 1.27 (colored)

use asprintf

Revision 1.27 / (download) - annotate - [select for diffs], Tue Jun 3 02:56:06 2003 UTC (20 years, 11 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_8_BASE, OPENBSD_3_8, OPENBSD_3_7_BASE, OPENBSD_3_7, OPENBSD_3_6_BASE, OPENBSD_3_6, OPENBSD_3_5_BASE, OPENBSD_3_5, OPENBSD_3_4_BASE, OPENBSD_3_4
Changes since 1.26: +3 -7 lines
Diff to previous 1.26 (colored)

Remove the advertising clause in the UCB license which Berkeley
rescinded 22 July 1999.  Proofed by myself and Theo.

Revision 1.26 / (download) - annotate - [select for diffs], Thu Apr 3 17:16:32 2003 UTC (21 years, 1 month ago) by millert
Branch: MAIN
Changes since 1.25: +5 -4 lines
Diff to previous 1.25 (colored)

Deal with files w/o a trailing newline before EOF.  Found by mpech@

Revision 1.25 / (download) - annotate - [select for diffs], Fri Feb 7 23:28:18 2003 UTC (21 years, 3 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_3_BASE, OPENBSD_3_3
Changes since 1.24: +3 -3 lines
Diff to previous 1.24 (colored)

More paranoia, make sure temp file owner matches real uid.

Revision 1.24 / (download) - annotate - [select for diffs], Sun Feb 2 18:38:22 2003 UTC (21 years, 3 months ago) by millert
Branch: MAIN
Changes since 1.23: +8 -5 lines
Diff to previous 1.23 (colored)

More paranoia when opening temp file; don't follow symlinks and
require that the link count be one.  Prompted by a report from Marc
Bevand.  deraadt@ OK

Revision 1.23 / (download) - annotate - [select for diffs], Wed Jul 31 22:08:42 2002 UTC (21 years, 9 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_2_BASE, OPENBSD_3_2
Changes since 1.22: +7 -6 lines
Diff to previous 1.22 (colored)

When I got removed the use of atexit() I missed the fact that edit()
calls pw_error() which in turn calls exit().  Now edit() returns
its status so the temp file gets cleaned up nicely if the user makes
no changes or if an error occurred.  Problem noticed by deraadt@

Revision 1.22 / (download) - annotate - [select for diffs], Thu Jun 27 19:02:40 2002 UTC (21 years, 10 months ago) by deraadt
Branch: MAIN
Changes since 1.21: +11 -10 lines
Diff to previous 1.21 (colored)

cleanup; mpech & millert ok

Revision 1.21 / (download) - annotate - [select for diffs], Thu Jul 12 05:16:57 2001 UTC (22 years, 10 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_1_BASE, OPENBSD_3_1, OPENBSD_3_0_BASE, OPENBSD_3_0
Changes since 1.20: +3 -3 lines
Diff to previous 1.20 (colored)

first pass at a -Wall cleanup

Revision 1.20 / (download) - annotate - [select for diffs], Tue Sep 26 16:00:08 2000 UTC (23 years, 7 months ago) by aaron
Branch: MAIN
CVS Tags: OPENBSD_2_9_BASE, OPENBSD_2_9, OPENBSD_2_8_BASE, OPENBSD_2_8
Changes since 1.19: +10 -6 lines
Diff to previous 1.19 (colored)

Do not permit non-printable characters in the passwd file; deraadt@ ok

Revision 1.19 / (download) - annotate - [select for diffs], Sun Mar 5 19:20:37 2000 UTC (24 years, 2 months ago) by aaron
Branch: MAIN
CVS Tags: OPENBSD_2_7_BASE, OPENBSD_2_7
Changes since 1.18: +3 -3 lines
Diff to previous 1.18 (colored)

Change prompt string from "Location:" to "Office Location:", to disambiguate
from what is expected, and to be consistent with finger(1); from FreeBSD.

Revision 1.18 / (download) - annotate - [select for diffs], Sun Dec 5 20:18:35 1999 UTC (24 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.17: +3 -6 lines
Diff to previous 1.17 (colored)

Fix temp file unlinking.  We use atexit() since the libutil passwd
routines do their own exit.

Revision 1.17 / (download) - annotate - [select for diffs], Sun Nov 28 13:08:17 1999 UTC (24 years, 5 months ago) by ho
Branch: MAIN
Changes since 1.16: +4 -3 lines
Diff to previous 1.16 (colored)

Check for size change as well as change in time. Scripted changes
usually finish in less than a second. ('vipw' already does this.)

Revision 1.16 / (download) - annotate - [select for diffs], Fri Aug 6 20:41:06 1999 UTC (24 years, 9 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_6_BASE, OPENBSD_2_6
Changes since 1.15: +5 -5 lines
Diff to previous 1.15 (colored)

uid_t and gid_t, and use %u

Revision 1.15 / (download) - annotate - [select for diffs], Thu May 28 19:13:26 1998 UTC (25 years, 11 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_5_BASE, OPENBSD_2_5, OPENBSD_2_4_BASE, OPENBSD_2_4
Changes since 1.14: +5 -3 lines
Diff to previous 1.14 (colored)

unlink tmpfile; noted by chris@dqc.org

Revision 1.14 / (download) - annotate - [select for diffs], Thu May 28 10:17:49 1998 UTC (25 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.13: +11 -2 lines
Diff to previous 1.13 (colored)

permit any gecos field to be empty

Revision 1.13 / (download) - annotate - [select for diffs], Mon Mar 30 06:59:31 1998 UTC (26 years, 1 month ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_3_BASE, OPENBSD_2_3
Changes since 1.12: +6 -5 lines
Diff to previous 1.12 (colored)

Y2K fixes from Andreas.Gunnarsson@emw.ericsson.se; culled from various places

Revision 1.12 / (download) - annotate - [select for diffs], Tue Jun 17 20:49:55 1997 UTC (26 years, 11 months ago) by kstailey
Branch: MAIN
CVS Tags: OPENBSD_2_2_BASE, OPENBSD_2_2
Changes since 1.11: +3 -3 lines
Diff to previous 1.11 (colored)

(foo *)NULL -> NULL

Revision 1.11 / (download) - annotate - [select for diffs], Mon Sep 23 09:41:02 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_1_BASE, OPENBSD_2_1, OPENBSD_2_0_BASE, OPENBSD_2_0
Changes since 1.10: +8 -6 lines
Diff to previous 1.10 (colored)

for errors, tell which line #

Revision 1.10 / (download) - annotate - [select for diffs], Sun Sep 1 13:06:51 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.9: +4 -4 lines
Diff to previous 1.9 (colored)

limit to around 1024 chars post expansion

Revision 1.9 / (download) - annotate - [select for diffs], Sat Aug 31 13:35:23 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.8: +11 -5 lines
Diff to previous 1.8 (colored)

constrain & expansion to LINE_MAX for safety

Revision 1.8 / (download) - annotate - [select for diffs], Sat Aug 31 01:55:33 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.7: +3 -3 lines
Diff to previous 1.7 (colored)

kill leaks; help from das33@cornell.edu

Revision 1.7 / (download) - annotate - [select for diffs], Fri Aug 30 13:29:47 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.6: +3 -3 lines
Diff to previous 1.6 (colored)

typo

Revision 1.6 / (download) - annotate - [select for diffs], Fri Aug 30 13:29:12 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.5: +4 -4 lines
Diff to previous 1.5 (colored)

watch for slimy link races, improvement by das33@cornell.edu & i

Revision 1.5 / (download) - annotate - [select for diffs], Mon Aug 26 22:55:37 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.4: +3 -2 lines
Diff to previous 1.4 (colored)

mem leak

Revision 1.4 / (download) - annotate - [select for diffs], Fri Jul 12 02:09:48 1996 UTC (27 years, 10 months ago) by downsj
Branch: MAIN
Changes since 1.3: +3 -3 lines
Diff to previous 1.3 (colored)

slight clarification

Revision 1.3 / (download) - annotate - [select for diffs], Wed Jun 26 05:31:55 1996 UTC (27 years, 10 months ago) by deraadt
Branch: MAIN
Changes since 1.2: +2 -1 lines
Diff to previous 1.2 (colored)

rcsid

Revision 1.2 / (download) - annotate - [select for diffs], Wed May 22 11:35:21 1996 UTC (28 years ago) by deraadt
Branch: MAIN
Changes since 1.1: +12 -12 lines
Diff to previous 1.1 (colored)

libutil

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Wed Oct 18 08:44:59 1995 UTC (28 years, 7 months ago) by deraadt
CVS Tags: netbsd_1_1
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

initial import of NetBSD tree

Revision 1.1 / (download) - annotate - [select for diffs], Wed Oct 18 08:44:59 1995 UTC (28 years, 7 months ago) by deraadt
Branch: MAIN

Initial revision

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.