Re: rcctl: find(1) service files in /etc/rc.d

2014-10-15 Thread Craig R. Skinner
On 2014-10-14 Tue 00:24 AM |, Antoine Jacoutot wrote: Makes sense yes. Not sure I'd want a function just for that one liner though. I'll commit something tomorrow. Nice one, using shell internals. This restricts the listing to files which are also executable: Index: rcctl.sh

Re: rcctl: find(1) service files in /etc/rc.d

2014-10-15 Thread Antoine Jacoutot
On Wed, Oct 15, 2014 at 10:11:18AM +0100, Craig R. Skinner wrote: On 2014-10-14 Tue 00:24 AM |, Antoine Jacoutot wrote: Makes sense yes. Not sure I'd want a function just for that one liner though. I'll commit something tomorrow. Nice one, using shell internals. This restricts

Re: Replace LibreSSL times() call

2014-10-15 Thread Joerg Jung
On 14 Oct 2014, at 22:08, Jonas 'Sortie' Termansen sor...@maxsi.org wrote: I noticed libressl's apps.c is using times(3), which is among the functions I am aggressively deprecating in my personal system. This patch switches it to use the clock_gettime and getrusage instead. I pondered using

More than just rtalloc1() - rtalloc(9) + man

2014-10-15 Thread Martin Pieuchot
So I'd appreciates some eyes on the diff below that touches all the existing rtalloc1() queries. The main change is indeed a rename to finally come back to a function with a sexy name introduced in 4.2BSD but with more goodies: rtalloc(9). But this diff also changes the meaning of the flags

Re: Replace LibreSSL times() call

2014-10-15 Thread Todd C. Miller
On Tue, 14 Oct 2014 22:08:20 +0200, Jonas 'Sortie' Termansen wrote: Unfortunately, OS X doesn't have clock_gettime, so the portable version will have to add back a times call as a fallback, or perhaps use gettimeofday (but this doesn't have the proper time-doesn't-go-backwards semantics). You

Re: rcctl: find(1) service files in /etc/rc.d

2014-10-15 Thread Vadim Zhukov
2014-10-15 13:11 GMT+04:00 Craig R. Skinner skin...@britvault.co.uk: On 2014-10-14 Tue 00:24 AM |, Antoine Jacoutot wrote: Makes sense yes. Not sure I'd want a function just for that one liner though. I'll commit something tomorrow. Nice one, using shell internals. This restricts the

implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Todd C. Miller
Since this came up in another thread. Trivial implementations of CLOCK_VIRTUAL and CLOCK_PROF, modeled after what FreeBSD does. - todd Index: sys/sys/_time.h === RCS file: /home/cvs/openbsd/src/sys/sys/_time.h,v retrieving

Re: delete kernel audio conversions code

2014-10-15 Thread Jonathan Armani
On Tue, Oct 14, 2014 at 09:09:26PM +0200, Alexandre Ratchov wrote: Since end 2011 we have complete audio format conversions code enabled by default that runs in user-mode (from any to any encoding, rate, and channel number combination). So there's no reason to keep the incomplete kernel

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Mark Kettenis
From: Todd C. Miller todd.mil...@courtesan.com Date: Wed, 15 Oct 2014 11:37:26 -0600 Since this came up in another thread. Trivial implementations of CLOCK_VIRTUAL and CLOCK_PROF, modeled after what FreeBSD does. Shouldn't this do a tuagg() on all the threads of the process like we do for

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Mark Kettenis
Date: Wed, 15 Oct 2014 20:18:10 +0200 (CEST) From: Mark Kettenis mark.kette...@xs4all.nl From: Todd C. Miller todd.mil...@courtesan.com Date: Wed, 15 Oct 2014 11:37:26 -0600 Since this came up in another thread. Trivial implementations of CLOCK_VIRTUAL and CLOCK_PROF, modeled after

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Mark Kettenis
Date: Wed, 15 Oct 2014 20:36:33 +0200 (CEST) From: Mark Kettenis mark.kette...@xs4all.nl Date: Wed, 15 Oct 2014 20:18:10 +0200 (CEST) From: Mark Kettenis mark.kette...@xs4all.nl From: Todd C. Miller todd.mil...@courtesan.com Date: Wed, 15 Oct 2014 11:37:26 -0600 Since this

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Todd C. Miller
On Wed, 15 Oct 2014 20:36:33 +0200, Mark Kettenis wrote: Hmm, looking at the FreeBSD man page... isn't CLOCK_PROF the same thing as CLOCK_PROCESS_CPUTIME_ID? I was wondering that too, but I get different results as they are not calculated the same way. CLOCK_PROCESS_CPUTIME_ID always yields a

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Todd C. Miller
On Wed, 15 Oct 2014 20:18:10 +0200, Mark Kettenis wrote: Shouldn't this do a tuagg() on all the threads of the process like we do for getrusage? Otherwise the CLOCK_VIRTUAL and CLOCK_PROF clocks will only be updated upon a context switch. Probably. I wasn't 100% sure going the rusage route

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Todd C. Miller
On Wed, 15 Oct 2014 21:04:43 +0200, Mark Kettenis wrote: Oh, and while FreeBSD seems to implement CLOCK_VIRTUAL and CLOCK_PROF as per-process, Solaris implements them as per-thread (but doesn't document them). And on Solaris CLOCK_PROF is just an alias for CLOCK_THREAD_CPUTIME_ID.

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Alexandre Ratchov
On Wed, Oct 15, 2014 at 11:37:26AM -0600, Todd C. Miller wrote: Since this came up in another thread. Trivial implementations of CLOCK_VIRTUAL and CLOCK_PROF, modeled after what FreeBSD does. out of curiousity, what program needs these?

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Todd C. Miller
On Wed, 15 Oct 2014 21:53:47 +0200, Alexandre Ratchov wrote: On Wed, Oct 15, 2014 at 11:37:26AM -0600, Todd C. Miller wrote: Since this came up in another thread. Trivial implementations of CLOCK_VIRTUAL and CLOCK_PROF, modeled after what FreeBSD does. out of curiousity, what program

Re: [Bulk] Re: Shadow TCP stacks

2014-10-15 Thread Kevin Chadwick
On Sat, 11 Oct 2014 13:38:49 -0400 Ian Grant wrote: No, the pre-shared keys are communicated over the VPN, as are the keys which encrypt the VPN's own data as it appears in the actual TCP packets which carry the tunnel through which the VPN operates. Perhaps I have missed something but if you

acpi printf

2014-10-15 Thread Wade, Daniel
Index: acpi_machdep.c === RCS file: /cvs/src/sys/arch/amd64/amd64/acpi_machdep.c,v retrieving revision 1.63 diff -u -p -r1.63 acpi_machdep.c --- acpi_machdep.c 19 Sep 2014 20:02:25 - 1.63 +++ acpi_machdep.c 16 Oct

Re: acpi printf

2014-10-15 Thread Theo de Raadt
I am not going to commit this, well not yet. Maybe ask again in a year or two. This is a subtle debugging technique that has saved us a lot of time. When these failures happen, it is best not to print a newline, and thus cause a screen scroll. That hits deep code paths, and sometimes has made a

Re: implement CLOCK_VIRTUAL and CLOCK_PROF

2014-10-15 Thread Philip Guenther
On Wed, Oct 15, 2014 at 2:08 PM, Todd C. Miller todd.mil...@courtesan.com wrote: On Wed, 15 Oct 2014 21:53:47 +0200, Alexandre Ratchov wrote: On Wed, Oct 15, 2014 at 11:37:26AM -0600, Todd C. Miller wrote: Since this came up in another thread. Trivial implementations of CLOCK_VIRTUAL and

Re: Replace LibreSSL times() call

2014-10-15 Thread Philip Guenther
On Tue, Oct 14, 2014 at 1:08 PM, Jonas 'Sortie' Termansen sor...@maxsi.org wrote: I noticed libressl's apps.c is using times(3), which is among the functions I am aggressively deprecating in my personal system. times() is a standard function (not even deprecated or obsolete in POSIX). Simply