Re: some more thinkpad docks support for azalia(4)

2015-08-23 Thread Jonathan Gray
On Mon, Aug 24, 2015 at 01:45:35PM +1000, Jonathan Gray wrote: > On Mon, Aug 24, 2015 at 03:15:51AM +0300, Dmitry Alenichev wrote: > > Index: azalia.h > > === > > RCS file: /cvs/src/sys/dev/pci/azalia.h,v > > retrieving revision 1.63 >

Re: some more thinkpad docks support for azalia(4)

2015-08-23 Thread Jonathan Gray
On Mon, Aug 24, 2015 at 03:15:51AM +0300, Dmitry Alenichev wrote: > Index: azalia.h > === > RCS file: /cvs/src/sys/dev/pci/azalia.h,v > retrieving revision 1.63 > diff -u -p -r1.63 azalia.h > --- azalia.h 20 Aug 2015 06:44:06 -

Re: kern_tame.c: fix strncmp call

2015-08-23 Thread Joerg Sonnenberger
On Sun, Aug 23, 2015 at 03:29:46PM -0700, patrick keshishian wrote: > On 8/23/15, Caspar Schutijser wrote: > > Patch below. > > > > Thanks, > > Caspar Schutijser > > > > > > Index: sys/kern/kern_tame.c > > === > > RCS file: /cvs/src/s

Re: worm(6) remove cheating bug

2015-08-23 Thread Rafael Zalamena
On Sun, Aug 23, 2015 at 06:07:46PM -0300, Rafael Zalamena wrote: > I just fixed a bug which allowed people to cheat in worm(6). This bug was > found out by deraadt@ when peer reviewing the mail thread in tech@ > 'Fwd: worm.c removing unused variables'. > > To reproduce the bug simply hold spacebar

restore(8): nanosecond precision

2015-08-23 Thread Philip Guenther
Diff below switches restore(8) to using utimensat() instead of utimes() so that file timestamps are restored with full nanosecond precision. Eliminates some pointless divisions... ok? Index: dirs.c === RCS file: /cvs/src/sbin/re

some more thinkpad docks support for azalia(4)

2015-08-23 Thread Dmitry Alenichev
Index: azalia.h === RCS file: /cvs/src/sys/dev/pci/azalia.h,v retrieving revision 1.63 diff -u -p -r1.63 azalia.h --- azalia.h20 Aug 2015 06:44:06 - 1.63 +++ azalia.h24 Aug 2015 00:15:01 - @@ -512,6 +512,7 @@ #def

Re: kern_tame.c: fix strncmp call

2015-08-23 Thread Alexander Hall
On 08/24/15 00:29, patrick keshishian wrote: On 8/23/15, Caspar Schutijser wrote: Patch below. Thanks, Caspar Schutijser Index: sys/kern/kern_tame.c === RCS file: /cvs/src/sys/kern/kern_tame.c,v retrieving revision 1.25 diff -u

Re: kern_tame.c: fix strncmp call

2015-08-23 Thread patrick keshishian
Apologies, my eyes failed me on this. On 8/23/15, patrick keshishian wrote: > On 8/23/15, Caspar Schutijser wrote: >> Patch below. >> >> Thanks, >> Caspar Schutijser >> >> >> Index: sys/kern/kern_tame.c >> === >> RCS file: /cvs/src/

Re: kern_tame.c: fix strncmp call

2015-08-23 Thread patrick keshishian
On 8/23/15, Caspar Schutijser wrote: > Patch below. > > Thanks, > Caspar Schutijser > > > Index: sys/kern/kern_tame.c > === > RCS file: /cvs/src/sys/kern/kern_tame.c,v > retrieving revision 1.25 > diff -u -p -r1.25 kern_tame.c > --- s

kern_tame.c: fix strncmp call

2015-08-23 Thread Caspar Schutijser
Patch below. Thanks, Caspar Schutijser Index: sys/kern/kern_tame.c === RCS file: /cvs/src/sys/kern/kern_tame.c,v retrieving revision 1.25 diff -u -p -r1.25 kern_tame.c --- sys/kern/kern_tame.c23 Aug 2015 19:32:20 -

worm(6) remove cheating bug

2015-08-23 Thread Rafael Zalamena
I just fixed a bug which allowed people to cheat in worm(6). This bug was found out by deraadt@ when peer reviewing the mail thread in tech@ 'Fwd: worm.c removing unused variables'. To reproduce the bug simply hold spacebar and your worm won't move. Highlights: * Use the unused time variables to

Re: Don't allow "rm -rf /"

2015-08-23 Thread Theo Buehler
On Sun, Aug 23, 2015 at 07:38:15AM -0400, Ted Unangst wrote: > Theo Buehler wrote: > > @@ -401,9 +401,10 @@ checkdot(char **argv) > > else > > p = *t; > > > > - if (ISDOT(p)) { > > + if (ISDOT(p) || *p == '\0') { > > if (!com

Re: Don't allow "rm -rf /"

2015-08-23 Thread Ted Unangst
Theo Buehler wrote: > In episode 103 of BSD Now, Bryan Cantrill talks about the fact that > on illumos "rm -rf /" is an error. It turns out that this behavior > is mandated by POSIX 1003.1-2013: > > "If either of the files dot or dot-dot are specified as the basename > portion of an operand (that

document clear(1) a bit more prominently

2015-08-23 Thread Theo Buehler
The clear(1) manpage is linked to the tput(1) manpage, but the clear utility is only mentioned in the history section. I suggest to make its appearance in the manual page a little more prominent. Index: tput.1 === RCS file: /var/cvs/

Re: tunefs(8): Fix handling of device names

2015-08-23 Thread Steven McDonald
On Sun, 23 Aug 2015 19:21:42 +1000 Steven McDonald wrote: > Also, section 6.9.1 clause 9 of C99[0] says that "each parameter has > automatic storage duration", so I think it's not safe to rely on a > function parameter still being a valid object outside of openpartition > (please correct me if I'

tunefs(8): Fix handling of device names

2015-08-23 Thread Steven McDonald
The openpartition function in tunefs(8) will currently set devicep, a char** passed in from main, to the path it attempted to opendev(3). This doesn't actually work as intended; it should be setting the value devicep points to instead of devicep itself. Also, section 6.9.1 clause 9 of C99[0] says

Don't allow "rm -rf /"

2015-08-23 Thread Theo Buehler
In episode 103 of BSD Now, Bryan Cantrill talks about the fact that on illumos "rm -rf /" is an error. It turns out that this behavior is mandated by POSIX 1003.1-2013: "If either of the files dot or dot-dot are specified as the basename portion of an operand (that is, the final pathname componen

opendev(3): Do not mask errno

2015-08-23 Thread Steven McDonald
Hi, Below is a diff to avoid masking errno from DIOCMAP in opendev(3). The intention of the existing code appears to be to try using path as a device name rather than a DUID in case of failure, but as far as I can tell, this is only desirable if DIOCMAP returns ENOENT anyway. Other kinds of error