OpenBSD CVS

CVS log for src/libexec/comsat/comsat.c


[BACK] Up to [local] / src / libexec / comsat

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.51 / (download) - annotate - [select for diffs], Wed Mar 8 04:43:05 2023 UTC (15 months ago) by guenther
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, HEAD
Changes since 1.50: +1 -3 lines
Diff to previous 1.50 (colored)

Delete obsolete /* ARGSUSED */ lint comments.

ok miod@ millert@

Revision 1.50 / (download) - annotate - [select for diffs], Mon Jul 12 15:09:18 2021 UTC (2 years, 10 months ago) by beck
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0
Changes since 1.49: +5 -5 lines
Diff to previous 1.49 (colored)

Change the error reporting pattern throughout the tree when unveil
fails to report the path that the failure occured on. Suggested by
deraadt@ after some tech discussion.

Work done and verified by Ashton Fagg <ashton@fagg.id.au>

ok deraadt@ semarie@ claudio@

Revision 1.49 / (download) - annotate - [select for diffs], Mon Sep 24 22:56:54 2018 UTC (5 years, 8 months ago) by deraadt
Branch: MAIN
CVS Tags: 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
Changes since 1.48: +9 -1 lines
Diff to previous 1.48 (colored)

unveil maildir, utmp, /tmp, and /dev.  For the vast number of people
using biff.

Revision 1.48 / (download) - annotate - [select for diffs], Mon Apr 3 17:23:39 2017 UTC (7 years, 2 months ago) by tedu
Branch: MAIN
CVS Tags: OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.47: +6 -2 lines
Diff to previous 1.47 (colored)

check return from pread, don't divide -1 for count

Revision 1.47 / (download) - annotate - [select for diffs], Mon Apr 3 17:07:58 2017 UTC (7 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.46: +3 -2 lines
Diff to previous 1.46 (colored)

use recallocarray() because the array contains data that can be observed

Revision 1.46 / (download) - annotate - [select for diffs], Sun Apr 2 00:53:37 2017 UTC (7 years, 2 months ago) by guenther
Branch: MAIN
Changes since 1.45: +3 -4 lines
Diff to previous 1.45 (colored)

Prefer pread() over lseek()+read()
open() only needs the mode argument if O_CREAT is present

ok beck@ deraadt@

Revision 1.45 / (download) - annotate - [select for diffs], Sat Apr 2 16:33:28 2016 UTC (8 years, 2 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1, OPENBSD_6_0_BASE, OPENBSD_6_0
Changes since 1.44: +4 -2 lines
Diff to previous 1.44 (colored)

Use open(tty, O_WRONLY) + fdopen() instead of fopen(tty, "w") to
keep stdio from opening with O_CREAT which would require pledge cpath.

Revision 1.44 / (download) - annotate - [select for diffs], Mon Oct 12 16:54:30 2015 UTC (8 years, 7 months ago) by uebayasi
Branch: MAIN
CVS Tags: OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.43: +5 -4 lines
Diff to previous 1.43 (colored)

Call pledge(2) after initial getsockname(2) to avoid "inet" addition.

From & OK deraadt@

Revision 1.43 / (download) - annotate - [select for diffs], Sat Oct 10 20:35:00 2015 UTC (8 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.42: +2 -2 lines
Diff to previous 1.42 (colored)

normalize a few more tame request orderings, to help review

Revision 1.42 / (download) - annotate - [select for diffs], Fri Oct 9 17:09:06 2015 UTC (8 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.41: +5 -1 lines
Diff to previous 1.41 (colored)

With nfs spool (fork + seteuid/setuid balony) support gone, it becomes
possible to pledge "stdio rpath wpath tty proc"
Noone uses this code anymore.  This is a demonstration...

Revision 1.41 / (download) - annotate - [select for diffs], Fri Oct 9 17:07:21 2015 UTC (8 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.40: +1 -8 lines
Diff to previous 1.40 (colored)

remove NFS spool support; it stands in the way of pledge(2)

Revision 1.40 / (download) - annotate - [select for diffs], Mon Jul 6 15:42:20 2015 UTC (8 years, 11 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8
Changes since 1.39: +10 -4 lines
Diff to previous 1.39 (colored)

Trim trailing whitespace from the comsat message before calling
strtonum() to parse the offset since mail.local writes a trailing
newline.  Otherwise comsat just discards the message.  OK deraadt@

Revision 1.39 / (download) - annotate - [select for diffs], Sat Apr 18 18:28:37 2015 UTC (9 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.38: +5 -2 lines
Diff to previous 1.38 (colored)

Convert many atoi() calls to strtonum(), adding range checks and failure
handling along the way.
Reviews by Brendan MacDonell, Jeremy Devenport, florian, doug, millert

Revision 1.38 / (download) - annotate - [select for diffs], Fri Jan 16 06:39:49 2015 UTC (9 years, 4 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.37: +4 -3 lines
Diff to previous 1.37 (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.37 / (download) - annotate - [select for diffs], Tue Dec 4 02:24:47 2012 UTC (11 years, 6 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6, OPENBSD_5_5_BASE, OPENBSD_5_5, OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3
Changes since 1.36: +1 -2 lines
Diff to previous 1.36 (colored)

remove some unnecessary sys/param.h inclusions

Revision 1.36 / (download) - annotate - [select for diffs], Tue Oct 27 23:59:31 2009 UTC (14 years, 7 months ago) by deraadt
Branch: MAIN
CVS Tags: 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.35: +1 -12 lines
Diff to previous 1.35 (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.35 / (download) - annotate - [select for diffs], Thu Aug 17 23:52:06 2006 UTC (17 years, 9 months ago) by ray
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6, OPENBSD_4_5_BASE, OPENBSD_4_5, OPENBSD_4_4_BASE, OPENBSD_4_4, OPENBSD_4_3_BASE, OPENBSD_4_3, OPENBSD_4_2_BASE, OPENBSD_4_2, OPENBSD_4_1_BASE, OPENBSD_4_1, OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.34: +10 -10 lines
Diff to previous 1.34 (colored)

recv(2) returns a ssize_t, so match cc with it.
st.st_mtime is a time_t, so match utmpmtime with it.
Check for -1 instead of <0 for some system calls.
Remove pointless casts.

OK dhill@ and millert@

Revision 1.34 / (download) - annotate - [select for diffs], Tue Nov 15 14:43:07 2005 UTC (18 years, 6 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9
Changes since 1.33: +5 -5 lines
Diff to previous 1.33 (colored)

the third arg of read() is size_t, not int (cast fix)
use UT_NAMESIZE more consistently
from Andrey Matveev

Revision 1.33 / (download) - annotate - [select for diffs], Thu Sep 16 10:53:02 2004 UTC (19 years, 8 months ago) by otto
Branch: MAIN
CVS Tags: OPENBSD_3_8_BASE, OPENBSD_3_8, OPENBSD_3_7_BASE, OPENBSD_3_7
Changes since 1.32: +3 -3 lines
Diff to previous 1.32 (colored)

more signal flag races; ok miod@

Revision 1.32 / (download) - annotate - [select for diffs], Tue Sep 14 22:14:13 2004 UTC (19 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.31: +4 -2 lines
Diff to previous 1.31 (colored)

ARGSUSED before signal handler with unused signo

Revision 1.31 / (download) - annotate - [select for diffs], Fri Sep 26 01:58:55 2003 UTC (20 years, 8 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_6_BASE, OPENBSD_3_6, OPENBSD_3_5_BASE, OPENBSD_3_5
Changes since 1.30: +3 -4 lines
Diff to previous 1.30 (colored)

free(NULL) allowed

Revision 1.30 / (download) - annotate - [select for diffs], Thu Sep 25 21:44:03 2003 UTC (20 years, 8 months ago) by millert
Branch: MAIN
Changes since 1.29: +3 -3 lines
Diff to previous 1.29 (colored)

Fix typo in revision 1.29; deraadt@ OK

Revision 1.29 / (download) - annotate - [select for diffs], Wed Sep 24 20:38:14 2003 UTC (20 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.28: +11 -4 lines
Diff to previous 1.28 (colored)

realloc fixes; ho ok

Revision 1.28 / (download) - annotate - [select for diffs], Thu Jun 19 22:35:34 2003 UTC (20 years, 11 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_4_BASE, OPENBSD_3_4
Changes since 1.27: +3 -3 lines
Diff to previous 1.27 (colored)

use fseeko; millert ok

Revision 1.27 / (download) - annotate - [select for diffs], Mon Jun 2 19:38:24 2003 UTC (21 years ago) by millert
Branch: MAIN
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], Fri Sep 6 19:43:54 2002 UTC (21 years, 9 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_3_BASE, OPENBSD_3_3, OPENBSD_3_2_BASE, OPENBSD_3_2
Changes since 1.25: +3 -3 lines
Diff to previous 1.25 (colored)

use socklen_t more; henning ok

Revision 1.25 / (download) - annotate - [select for diffs], Thu Aug 22 17:45:16 2002 UTC (21 years, 9 months ago) by pb
Branch: MAIN
Changes since 1.24: +8 -2 lines
Diff to previous 1.24 (colored)

fix int overflow in statbf.st_size, from netbsd PR#17933

as by request from deraadt@

Revision 1.24 / (download) - annotate - [select for diffs], Wed Jul 3 23:39:03 2002 UTC (21 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.23: +8 -18 lines
Diff to previous 1.23 (colored)

KNF

Revision 1.23 / (download) - annotate - [select for diffs], Thu Jun 20 18:26:49 2002 UTC (21 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.22: +5 -5 lines
Diff to previous 1.22 (colored)

fix patch; moritz@jodeit.org

Revision 1.22 / (download) - annotate - [select for diffs], Wed Jun 19 22:44:04 2002 UTC (21 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.21: +15 -8 lines
Diff to previous 1.21 (colored)

handle non-terminated things better; moritz@jodeit.org

Revision 1.21 / (download) - annotate - [select for diffs], Sat Feb 16 21:27:29 2002 UTC (22 years, 3 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_1_BASE, OPENBSD_3_1
Changes since 1.20: +8 -8 lines
Diff to previous 1.20 (colored)

Part one of userland __P removal.  Done with a simple regexp with some minor hand editing to make comments line up correctly.  Another pass is forthcoming that handles the cases that could not be done automatically.

Revision 1.20 / (download) - annotate - [select for diffs], Fri Dec 7 18:45:32 2001 UTC (22 years, 6 months ago) by mpech
Branch: MAIN
Changes since 1.19: +11 -11 lines
Diff to previous 1.19 (colored)

kill more registers;

millert@ ok

Revision 1.19 / (download) - annotate - [select for diffs], Sun Nov 18 21:25:55 2001 UTC (22 years, 6 months ago) by deraadt
Branch: MAIN
Changes since 1.18: +15 -6 lines
Diff to previous 1.18 (colored)

Ensure SA_RESTART is not set on SIGALRM.  With it set, the SIGALRM is not
seen after a successful recv().  This affects some other programs too..
but turning off SA_RESTART requires SIGNIFICANT analysis -- not for the
faint of heart.

Revision 1.18 / (download) - annotate - [select for diffs], Sat Nov 17 19:54:56 2001 UTC (22 years, 6 months ago) by deraadt
Branch: MAIN
Changes since 1.17: +3 -3 lines
Diff to previous 1.17 (colored)

volatile sig_atomic_t

Revision 1.17 / (download) - annotate - [select for diffs], Sun Jul 8 21:18:06 2001 UTC (22 years, 11 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_0_BASE, OPENBSD_3_0
Changes since 1.16: +4 -4 lines
Diff to previous 1.16 (colored)

-Wall

Revision 1.16 / (download) - annotate - [select for diffs], Sat May 12 01:46:54 2001 UTC (23 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.15: +3 -4 lines
Diff to previous 1.15 (colored)

strlcpy

Revision 1.15 / (download) - annotate - [select for diffs], Sun Jan 28 19:34:27 2001 UTC (23 years, 4 months ago) by niklas
Branch: MAIN
CVS Tags: OPENBSD_2_9_BASE, OPENBSD_2_9
Changes since 1.14: +3 -1 lines
Diff to previous 1.14 (colored)

$OpenBSD$

Revision 1.14 / (download) - annotate - [select for diffs], Wed Jan 17 19:21:48 2001 UTC (23 years, 4 months ago) by deraadt
Branch: MAIN
Changes since 1.13: +7 -6 lines
Diff to previous 1.13 (colored)

use sig_atomic_t, and check for signal flag more often

Revision 1.13 / (download) - annotate - [select for diffs], Thu Jan 11 22:36:22 2001 UTC (23 years, 5 months ago) by deraadt
Branch: MAIN
Changes since 1.12: +20 -7 lines
Diff to previous 1.12 (colored)

change signal handler to set a flag, and then in the main loop do
the work that this handler used to do.  many signal handlers in the
tree should be changed to this, since a large percentage of them
have raceable stuff in them; like mixing malloc's and stdio inside and
outside the handler.. terrrible stuff

Revision 1.12 / (download) - annotate - [select for diffs], Tue Aug 17 09:13:13 1999 UTC (24 years, 9 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_2_8_BASE, OPENBSD_2_8, OPENBSD_2_7_BASE, OPENBSD_2_7, OPENBSD_2_6_BASE, OPENBSD_2_6
Changes since 1.11: +2 -2 lines
Diff to previous 1.11 (colored)

More <sys/file.h> vs. <fcntl.h> and open() flags fixes.

Revision 1.11 / (download) - annotate - [select for diffs], Wed Jun 23 20:39:12 1999 UTC (24 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.10: +2 -2 lines
Diff to previous 1.10 (colored)

use sockaddr_storage

Revision 1.10 / (download) - annotate - [select for diffs], Sun Feb 21 08:30:00 1999 UTC (25 years, 3 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_5_BASE, OPENBSD_2_5
Changes since 1.9: +2 -2 lines
Diff to previous 1.9 (colored)

vis() buf overflow

Revision 1.9 / (download) - annotate - [select for diffs], Mon Jul 13 02:11:14 1998 UTC (25 years, 11 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_2_4_BASE, OPENBSD_2_4
Changes since 1.8: +3 -3 lines
Diff to previous 1.8 (colored)

ftpd: sleep for an indeterminate amount for non-existant logins
      to simulate a crypt, like login does.
Use SEEK_* not L_* and kill some 0L's used in lseek while we're there.

Revision 1.8 / (download) - annotate - [select for diffs], Fri Jul 10 08:06:02 1998 UTC (25 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.7: +2 -2 lines
Diff to previous 1.7 (colored)

do not syslog() with "\n"; skipped smtpd/named/ipmon; 12 minutes of dabbling

Revision 1.7 / (download) - annotate - [select for diffs], Thu Nov 20 23:31:50 1997 UTC (26 years, 6 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_3_BASE, OPENBSD_2_3
Changes since 1.6: +2 -2 lines
Diff to previous 1.6 (colored)

do not exit(-1)

Revision 1.6 / (download) - annotate - [select for diffs], Tue Aug 5 23:35:23 1997 UTC (26 years, 10 months ago) by angelos
Branch: MAIN
CVS Tags: OPENBSD_2_2_BASE, OPENBSD_2_2
Changes since 1.5: +3 -1 lines
Diff to previous 1.5 (colored)

More errno saving.

Revision 1.5 / (download) - annotate - [select for diffs], Mon Aug 4 19:25:07 1997 UTC (26 years, 10 months ago) by deraadt
Branch: MAIN
Changes since 1.4: +4 -1 lines
Diff to previous 1.4 (colored)

save errno in sigchld handlers

Revision 1.4 / (download) - annotate - [select for diffs], Sun Dec 22 03:41:12 1996 UTC (27 years, 5 months ago) by tholo
Branch: MAIN
CVS Tags: OPENBSD_2_1_BASE, OPENBSD_2_1
Changes since 1.3: +4 -2 lines
Diff to previous 1.3 (colored)

Deal with _POSIX_SAVED_IDS when relinquishing privileges

Revision 1.3 / (download) - annotate - [select for diffs], Tue Aug 27 11:43:52 1996 UTC (27 years, 9 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_0_BASE, OPENBSD_2_0
Changes since 1.2: +6 -4 lines
Diff to previous 1.2 (colored)

vis

Revision 1.2 / (download) - annotate - [select for diffs], Tue Aug 27 10:22:04 1996 UTC (27 years, 9 months ago) by deraadt
Branch: MAIN
Changes since 1.1: +2 -2 lines
Diff to previous 1.1 (colored)

strncpy correctly

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Wed Oct 18 08:43:15 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:43:15 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.