Re: chmod.c undefined behavior

2014-09-24 Thread Otto Moerbeek
On Wed, Sep 24, 2014 at 12:10:47PM +0300, Matti Karnaattu wrote: > I noticed that chmod.c have uninitialized variable char *ep that was > used. This diff clarify what I mean. &ep is passed to strtoul(), wonder what it does with it... -Otto > > > Index: chmod.c > =

Re: swap affinity?

2014-09-19 Thread Otto Moerbeek
On Fri, Sep 19, 2014 at 10:05:35PM -0700, patrick keshishian wrote: > Hi, > > Just ran into something strange. I was running 'sudo cdio cdrip' > and in another shell running a memory-hungry perl script, this > caused a bunch of processes to swap out (namely Xorg). Once > the cdrip was done, and I

Re: [PATCH] Option for mount_tmpfs to populate the volume after creation.

2014-09-19 Thread Otto Moerbeek
On Fri, Sep 19, 2014 at 10:21:13PM +1000, Adam wrote: > Patch for argument parsing below. > > Diff taken in relation to Revision 3 of the aforementioned patch. > > I do not understand why this should be a separate diff for this, as it > is essentially part of the functionality itself. > > Let m

Re: [PATCH] Option for mount_tmpfs to populate the volume after creation.

2014-09-18 Thread Otto Moerbeek
On Thu, Sep 18, 2014 at 08:40:44AM +0100, bytevolc...@safe-mail.net wrote: > This patch adds an option "-t template" to mount_tmpfs, which > populates the new tmpfs volume with a directory > immediately after creation. > > Man page update included for explanation. > > Much of the code was grafte

Re: faster malloc in threads

2014-07-14 Thread Otto Moerbeek
On Sat, Jul 12, 2014 at 01:10:38PM -0400, Ted Unangst wrote: > On Fri, Jul 11, 2014 at 08:11, Ted Unangst wrote: > > >> I also think there's one simple case that can be added: the MMAP call > >> at the bottom of map(). > > On further inspection, I think this needed a slight reordering to be > sa

Re: lynx: disable old protocols

2014-07-13 Thread Otto Moerbeek
On Sun, Jul 13, 2014 at 02:26:10AM -0500, Shawn K. Quinn wrote: > On Sat, 2014-07-12 at 23:58 -0700, William Orr wrote: > > wrt. auditing it, should we send patches here? Or upstream? > > I'd send them both places, if they apply cleanly to both sets of code. > Otherwise, send them here. I'd love

Re: faster malloc in threads

2014-07-11 Thread Otto Moerbeek
On Fri, Jul 11, 2014 at 06:28:04AM -0400, Ted Unangst wrote: > We don't need to hold the malloc lock when making syscalls like mmap > and munmap if we're just a little careful about the order of > operations. This will allow other threads to concurrently allocate > perhaps smaller chunks while the

Re: PATCH: add more malloc.conf details to malloc.3

2014-07-11 Thread Otto Moerbeek
On Fri, Jul 11, 2014 at 01:38:23AM -0600, Theo de Raadt wrote: > I am a bit concerned. The description is trying too hard to be overly > precise, and may be cumbersome for the typical reader of this page. indeed, and I also dislike putting too much implementation details into a man page. Things

Re: growfs error message, lack of comprehension

2014-07-08 Thread Otto Moerbeek
On Tue, Jul 08, 2014 at 09:41:08PM -0500, Adam Thompson wrote: > On 5.4-RELEASE, I'm trying to use growfs to expand a root filesystem. I've > grown the disk from 2GB to 10GB, I've used disklabel(8) to adjust the > OpenBSD area and the size of partition 'a'. All those numbers line up. > Rebooting

Re: sort(1) updates

2014-07-06 Thread Otto Moerbeek
On Sat, Jul 05, 2014 at 01:09:51PM -0400, Jared Yanovich wrote: > On Wed, Jul 02, 2014 at 12:45:04PM -0400, Jared Yanovich wrote: > > > Index: fsort.c > > If this patch is accepted it should include the NetBSD copyright I forgot to > include. > > There's more to be done here, such as: > > $

Re: sort(1) updates

2014-07-02 Thread Otto Moerbeek
On Wed, Jul 02, 2014 at 02:11:11PM -0400, Ted Unangst wrote: > On Wed, Jul 02, 2014 at 12:37, Otto Moerbeek wrote: > > On Tue, Jul 01, 2014 at 03:56:39PM -0400, Jared Yanovich wrote: > > > >> On Mon, Jun 30, 2014 at 11:53:04AM +0200, Otto Moerbeek wrote: > >&g

Re: sort(1) updates

2014-07-02 Thread Otto Moerbeek
> Op 2 jul. 2014 om 15:03 heeft Jared Yanovich het > volgende geschreven: > >> On Wed, Jul 02, 2014 at 12:37:53PM +0200, Otto Moerbeek wrote: >> >> On Tue, Jul 01, 2014 at 03:56:39PM -0400, Jared Yanovich wrote: >> >> This works better indeed. But

Re: sort(1) updates

2014-07-02 Thread Otto Moerbeek
On Tue, Jul 01, 2014 at 03:56:39PM -0400, Jared Yanovich wrote: > On Mon, Jun 30, 2014 at 11:53:04AM +0200, Otto Moerbeek wrote: > > > This indeed solves some problems, but I have a test file on which it cores. > > Patch relative to the original diff I posted. > > d

Re: cvs admin for commitids

2014-06-30 Thread Otto Moerbeek
On Sun, Jun 29, 2014 at 07:37:18PM -0500, joshua stein wrote: > This adds a -C option to cvs's admin command which can add, change, > or delete a revision's commitid. I couldn't find any similar > functionality in any other CVS implementations, nor any using 'admin > -C'. > > Add or change a com

Re: sort(1) updates

2014-06-30 Thread Otto Moerbeek
On Sun, Jun 29, 2014 at 06:48:32PM -0400, Jared Yanovich wrote: > Hi, > > sort(1) does some funky things and isn't hard to break: > > $ perl -e 'print "\n"x117000,"x\n"' | sort | sort -c > > This patch contains a few changes from NetBSD to correct the behavior > regarding > ordering of appen

Re: Undefined symbol in ld.so

2014-06-24 Thread Otto Moerbeek
On Tue, Jun 24, 2014 at 01:30:55AM -0700, William Orr wrote: > ld.so in -current isn't building right now, due to an undefined reference to > _dl_realloc caused by the recent addition of _dl_reallocarray. The following > diff implements _dl_realloc, largely copied from the implementation in > lib/

Re: ld.so take 2

2014-06-14 Thread Otto Moerbeek
On Fri, Jun 06, 2014 at 10:11:57AM +0200, Otto Moerbeek wrote: > On Thu, Jun 05, 2014 at 09:41:03AM -0600, Theo de Raadt wrote: > > > > The new malloc has been comitted, so now take the next step. > > > > > > This changes _dl_malloc to a regular non-zeroing _dl

Re: mfi(4) vs WT and WB

2014-06-10 Thread Otto Moerbeek
On Tue, Jun 10, 2014 at 09:52:23PM +0200, Mark Kettenis wrote: > > Date: Tue, 10 Jun 2014 21:34:56 +0200 > > From: Otto Moerbeek > > > > On Fri, Jun 06, 2014 at 08:54:24PM +0200, Otto Moerbeek wrote: > > > > > This volumes feel pretty fast, so I suspec

Re: mfi(4) vs WT and WB

2014-06-10 Thread Otto Moerbeek
On Fri, Jun 06, 2014 at 08:54:24PM +0200, Otto Moerbeek wrote: > This volumes feel pretty fast, so I suspect caching mode is OK. Still > it is confusing to have a flag that doesn't reflect reality. > > I'm planning to upgrade the firmware next week. We'll see if that

Re: mfi(4) vs WT and WB

2014-06-06 Thread Otto Moerbeek
On Fri, Jun 06, 2014 at 02:46:35PM -0400, Jim wrote: > On Fri, Jun 06, 2014 at 11:45:49AM +0200, Otto Moerbeek wrote: > > Hi, > > > > I have an PERC 6/i Integrated adapter here: > > > > mfi0 at pci2 dev 0 function 0 "Symbios Logic SAS1078" rev 0x04:

mfi(4) vs WT and WB

2014-06-06 Thread Otto Moerbeek
Hi, I have an PERC 6/i Integrated adapter here: mfi0 at pci2 dev 0 function 0 "Symbios Logic SAS1078" rev 0x04: apic 1 int 0 mfi0: "PERC 6/i Integrated", firmware 6.2.0-0013, 256MB cache Which has an OK battery but still reports itself as being in WT mode: # sysctl hw.sensors.mfi0.indicator0 h

Re: ld.so take 2

2014-06-06 Thread Otto Moerbeek
pp = NULL; } + retval[pos] = NULL; return (retval); badret: Index: reallocarray.c === RCS file: reallocarray.c diff -N reallocarray.c --- /dev/null 1 Jan 1970 00:00:00 - +++ reallocarray.c

Re: ld.so take 2

2014-06-05 Thread Otto Moerbeek
On Thu, Jun 05, 2014 at 09:04:25AM -0600, Theo de Raadt wrote: > + if (optr != NULL) { > + _dl_write(STDERR_FILENO, msg1, sizeof(msg1) - 1); > + _dl_exit(7); > + } > > I think this is a trap. A true realloc is not much to add. It can > be the simple "alwa

Re: ld.so take 2

2014-06-05 Thread Otto Moerbeek
OK, Grrr... messed this up, sent thw wrong version. Both the To: header and the text contain errors, but the intend should be clear. Diff is the right version. Take care when replying. -Otto On Thu, Jun 05, 2014 at 02:22:01PM +0200, Otto Moerbeek wrote: > Hi, > > The new m

ld.so take 2

2014-06-05 Thread Otto Moerbeek
1 Jan 1970 00:00:00 - +++ reallocarray.c 5 Jun 2014 11:22:36 - @@ -0,0 +1,47 @@ +/* $OpenBSD: reallocarray.c,v 1.1 2014/05/08 21:43:49 deraadt Exp $ */ +/* + * Copyright (c) 2008 Otto Moerbeek + * + * Permission to use, copy, modify, and distribute this software for

ld.so malloc

2014-06-02 Thread Otto Moerbeek
- /dev/null 1 Jan 1970 00:00:00 - +++ malloc.c2 Jun 2014 12:35:48 - @@ -0,0 +1,1022 @@ +/* $OpenBSD: malloc.c,v 1.166 2014/05/26 06:19:07 otto Exp $ */ +/* + * Copyright (c) 2008, 2010, 2011 Otto Moerbeek + * Copyright (c) 2012 Matthew Dempsky + * Copyright (c) 200

move random bytes buffer to mmap'ed region

2014-05-29 Thread Otto Moerbeek
Hi, more localized data access, and there's room in the allocated page(s) anyway. ok? -Otto Index: malloc.c === RCS file: /cvs/src/lib/libc/stdlib/malloc.c,v retrieving revision 1.166 diff -u -p -r1.166 malloc.c --- malloc.

move all stats under MALLOC_STATS

2014-05-22 Thread Otto Moerbeek
Hi, some stats are always computed. Move them under #ifdef MALLOC_STATS And a small thing for error reporting. ok? -Otto Index: malloc.c === RCS file: /cvs/src/lib/libc/stdlib/malloc.c,v retrieving revision 1.165 diff -u

Re: better free checking

2014-05-16 Thread Otto Moerbeek
On Wed, May 14, 2014 at 03:28:02PM -0400, Ted Unangst wrote: > As I learned the hard way not long ago, free() doesn't detect all > errors because of the delay mechanism. We can make two improvements. > > 1. Perform the sanity checking from free_bytes before we insert > something into the delay ar

Re: better free checking

2014-05-15 Thread Otto Moerbeek
On Wed, May 14, 2014 at 03:28:02PM -0400, Ted Unangst wrote: > As I learned the hard way not long ago, free() doesn't detect all > errors because of the delay mechanism. We can make two improvements. > > 1. Perform the sanity checking from free_bytes before we insert > something into the delay ar

Re: IPv6 by default

2014-04-29 Thread Otto Moerbeek
On Tue, Apr 29, 2014 at 04:57:28PM +, Christian Weisgerber wrote: > On 2014-04-29, Mark Kettenis wrote: > > >> Google's data [1] shows a few third-world countries where what you say > >> is true, plus Japan because of a single particularly broken ISP [2]. > > > > Isn't there a correlation be

Re: IPv6 by default

2014-04-29 Thread Otto Moerbeek
On Tue, Apr 29, 2014 at 10:04:35AM -0400, Simon Perreault wrote: > Le 2014-04-29 09:55, Henning Brauer a ?crit : > >> Wouldn't it be better if libasr would run A and requests in > >> parallel? Whichever response arrives first "wins". > > no, since that gives extremely unpredictable results. >

Re: mo junk mo problems

2014-04-22 Thread Otto Moerbeek
On Tue, Apr 22, 2014 at 09:49:42PM -0400, Ted Unangst wrote: > On Mon, Apr 14, 2014 at 12:12, Otto Moerbeek wrote: > > On Sun, Apr 13, 2014 at 06:34:17PM -0400, Ted Unangst wrote: > > > >> I took another look at the way junk works in malloc, and there's a few >

Re: [patch ping.c] replace malloc & memset with calloc

2014-04-22 Thread Otto Moerbeek
fdmaskp, 0, fdmasks); > FD_SET(s, fdmaskp); > if (select(s + 1, (fd_set *)fdmaskp, (fd_set *)NULL, > (fd_set *)NULL, &timeout) < 1) > > > Quoting Otto Moerbeek : > > >On Tue, Apr 2

Re: [patch ping.c] replace malloc & memset with calloc

2014-04-21 Thread Otto Moerbeek
On Tue, Apr 22, 2014 at 12:45:25AM -0400, Peter Malone wrote: > Hi, > > malloc & memset can be replaced with calloc in ping.c. Please see below for > patch details: Better rework this to get rid of fdmasks. -Otto > > Index: ping.c >

Re: ffs2 boot

2014-04-17 Thread Otto Moerbeek
that long to newfs the 10 kvm's I plan on > >using ;) > >>> > >>> On Thu, Apr 17, 2014 at 5:09 AM, Otto Moerbeek > >wrote: > >>>> On Wed, Apr 16, 2014 at 11:16:00PM -0700, Philip Guenther wrote: > >>>> > >>>>> O

Re: ffs2 boot

2014-04-17 Thread Otto Moerbeek
On Wed, Apr 16, 2014 at 11:16:00PM -0700, Philip Guenther wrote: > On Thursday, April 17, 2014, Otto Moerbeek wrote: > ... > > > But bear in mind that ffs2 has more overhead in terms of metadata. > > IMO, making it the default is not a good idea. > > > > You

Re: ffs2 boot

2014-04-16 Thread Otto Moerbeek
ufs_stat,ufs_readdir}, > > + { ufs2_open,ufs2_close,ufs2_read,ufs2_write, > > ufs2_seek, > > + ufs2_stat,ufs2_readdir}, > > #ifdef notdef > > { fat_open,fat_close,fat_read,fat_write,

Re: segfault in dhclient 5.4 please help

2014-04-15 Thread Otto Moerbeek
> Op 15 apr. 2014 om 13:13 heeft Kenneth Westerback het > volgende geschreven: > >> On 15 April 2014 08:34, Otto Moerbeek wrote: >>> On Mon, Apr 14, 2014 at 09:32:43PM -0400, sven falempin wrote: >>> >>> so i got gdb back to the machine because

Re: segfault in dhclient 5.4 please help

2014-04-14 Thread Otto Moerbeek
On Mon, Apr 14, 2014 at 09:32:43PM -0400, sven falempin wrote: > so i got gdb back to the machine because i cannot reproduce outside of the > box. > gdb too old cannot gcore. > > The state is nasty, but i do get the trace of the dhcp transaction. > > [..] > DHCPREQUEST on trunk0 to 255.255.255.

Re: malloc chunk info in region

2014-04-14 Thread Otto Moerbeek
On Mon, Apr 14, 2014 at 02:21:27PM -0400, Ted Unangst wrote: > On Mon, Apr 14, 2014 at 20:09, Otto Moerbeek wrote: > >> > static int > >> > -insert(struct dir_info *d, void *p, size_t sz, void *f) > >> > +insert(struct dir_info *d, void *p, uintptr_t sz, vo

Re: malloc chunk info in region

2014-04-14 Thread Otto Moerbeek
On Mon, Apr 14, 2014 at 11:54:32AM -0600, Bob Beck wrote: > On Mon, Apr 14, 2014 at 11:39 AM, Ted Unangst wrote: > > Small tweak. Use a union, instead of casts. There's still casting for > > the call to insert(), but I think this is a little better. Also use > > the correct type for the insert()

Re: mo junk mo problems

2014-04-14 Thread Otto Moerbeek
On Sun, Apr 13, 2014 at 06:34:17PM -0400, Ted Unangst wrote: > I took another look at the way junk works in malloc, and there's a few > improvements I'd like to make. > > 1. Remove the Z option. In general, I think malloc options should make > programs crash more, not less. This option is a banda

Re: 5.5beta wierds

2014-01-22 Thread Otto Moerbeek
On Tue, Jan 21, 2014 at 11:58:44AM -0700, Todd C. Miller wrote: > On Tue, 21 Jan 2014 10:44:00 +0100, Otto Moerbeek wrote: > > > And here's the man page diff, our ctime and asctime actually do not > > ever return NULL, while posix allows that. > > Isn't i

Re: 5.5beta wierds

2014-01-21 Thread Otto Moerbeek
On Tue, Jan 21, 2014 at 09:34:51AM +0100, Otto Moerbeek wrote: > On Tue, Jan 21, 2014 at 09:08:18PM +1300, Philip Guenther wrote: > > > On Tue, Jan 21, 2014 at 8:33 PM, Otto Moerbeek wrote: > > ... > > > Right. what happens is that localtime(3) returns NULL, be

Re: 5.5beta wierds

2014-01-21 Thread Otto Moerbeek
On Tue, Jan 21, 2014 at 09:08:18PM +1300, Philip Guenther wrote: > On Tue, Jan 21, 2014 at 8:33 PM, Otto Moerbeek wrote: > ... > > Right. what happens is that localtime(3) returns NULL, because the > > year is not representable as an int. struct tm.tm_year must be an int >

Re: 5.5beta wierds

2014-01-20 Thread Otto Moerbeek
On Tue, Jan 21, 2014 at 03:52:23PM +1100, Rod Whitworth wrote: > I had a short run-up of the first 5.5 i386 snap install and it > looked pretty much as expected but a more recent one showed up and I > grabbed it and loaded it onto my little Shuttle. > > The dmesg is below but I'll make some obser

Re: Weird loop in ftp client

2013-11-23 Thread Otto Moerbeek
On Fri, Nov 22, 2013 at 10:04:02PM +0100, Maxime Villard wrote: > Le 22/11/2013 17:48, Ted Unangst a ??crit : > > On Fri, Nov 22, 2013 at 10:09, Stuart Henderson wrote: > >> On 2013/11/22 07:25, Maxime Villard wrote: > > > >>> If write() fails without EPIPE, d is decremented, and the function > >

Re: make ftp(1) ignore leading whitespace in URLs

2013-11-05 Thread Otto Moerbeek
On Tue, Nov 05, 2013 at 08:54:00PM +0100, Marc Espie wrote: > On Tue, Nov 05, 2013 at 02:20:00PM +0100, Janne Johansson wrote: > > I think this would help the port "yt" to not crash on such urls, and I > > think it uses ftp to collect the youtube movies. > > Fix yt, then. > > I hate this. Like o

Re: Possible buffer overflow in nd6_rtr.c

2013-10-03 Thread Otto Moerbeek
On Thu, Oct 03, 2013 at 08:42:17AM -0700, Loganaden Velvindron wrote: > Hi All, > > >From nd6_rtr.c: > > bzero(&ifra, sizeof(ifra)); > /* >* in6_update_ifa() does not use ifra_name, but we accurately set it >* for safety. >*/ > strncpy(ifra.ifra_name, if

loongson panic on current

2013-09-28 Thread Otto Moerbeek
Hi, I recently upgraded my yeeloong and now I'm seeing this panic, it happened twice already. All hand-transcribed. panic: kernel diagnostic assertion "p->p_wchan == NULL" failed: file "../../../../kern/kern_sched.c", line 322 trace: Debugger+0x4 panic+0xe4 addupc_intr+0x0 active process is 2

Re: rman.h

2013-09-17 Thread Otto Moerbeek
Op 17 sep. 2013 om 21:54 heeft Kyle R W Milz het volgende geschreven: > tech@, > > I was porting over some freebsd kernel code and came across a struct > rman and some rman_* utility functions, defined in fbsd's sys/rman.h . > > Does obsd have an equivalent interface? It might help if you ex

Re: Iso image integrity verification

2013-09-12 Thread Otto Moerbeek
On Thu, Sep 12, 2013 at 09:22:51AM -0400, Kenneth R Westerback wrote: > On Thu, Sep 12, 2013 at 10:49:30AM +0200, InterNetX - Robert Garrett wrote: > > The real problem here is that in order to be added to certain lists > > of trusted PKI providers, you must be audited by security Assessors > > on

Re: Iso image integrity verification

2013-09-11 Thread Otto Moerbeek
On Wed, Sep 11, 2013 at 03:17:20PM +0300, Valentin Zagura wrote: > Yes, we know, but that file can also be easily compromised if it's not > available for download with a secure protocol (HTTPS) So get the CD. You'll support the project as well. -Otto > > On Wed, Sep 11, 2013 at 1:59 PM,

Re: src/sbin/ifconfig: missing include

2013-08-19 Thread Otto Moerbeek
On Mon, Aug 19, 2013 at 12:52:41PM +0200, David Coppa wrote: > > This misses util.h: > > cc -O2 -pipe -fno-pie -Wall -DINET6 -c /usr/src/sbin/ifconfig/ifconfig.c > /usr/src/sbin/ifconfig/ifconfig.c: In function 'setifwpakey': > /usr/src/sbin/ifconfig/ifconfig.c:1759: warning: implicit declara

Re: SSLHonorCipherOrder for OpenBSD's httpd

2013-07-12 Thread Otto Moerbeek
Example lines for the config file. ok? -Otto Index: httpd.conf === RCS file: /cvs/src/usr.sbin/httpd/conf/httpd.conf,v retrieving revision 1.26 diff -u -p -r1.26 httpd.conf --- httpd.conf 3 Jun 2009 18:28:21 - 1.2

Re: SSLHonorCipherOrder for OpenBSD's httpd

2013-07-11 Thread Otto Moerbeek
On Wed, Jul 10, 2013 at 10:28:32AM +0200, Otto Moerbeek wrote: > On Sun, Jul 07, 2013 at 10:17:11PM -0700, Aaron Stellman wrote: > > > On Mon, Jul 08, 2013 at 07:06:43AM +0200, Otto Moerbeek wrote: > > > I think you missed the renogiate case. Anyway, I posted almost the >

Re: SSLHonorCipherOrder for OpenBSD's httpd

2013-07-10 Thread Otto Moerbeek
On Sun, Jul 07, 2013 at 10:17:11PM -0700, Aaron Stellman wrote: > On Mon, Jul 08, 2013 at 07:06:43AM +0200, Otto Moerbeek wrote: > > I think you missed the renogiate case. Anyway, I posted almost the > > same diff some time ago. > > You're right -- renegotiate case w

Re: base apache and HonorCipherOrder

2013-07-09 Thread Otto Moerbeek
On Mon, Jul 08, 2013 at 01:53:46PM +1000, Damien Miller wrote: > On Sun, 7 Jul 2013, Aaron Stellman wrote: > > > On Tue, Apr 23, 2013 at 09:08:19AM +0200, Otto Moerbeek wrote: > > > If there is any interest, I might add the manual stuff, get ok's and > > > co

Re: SSLHonorCipherOrder for OpenBSD's httpd

2013-07-07 Thread Otto Moerbeek
On Sun, Jul 07, 2013 at 08:18:18PM -0700, Aaron Stellman wrote: > As you may or may not know, SSLHonorCipherOrder is supported since > apache 2.1. > > This diff ports this feature to OpenBSD's httpd. Its effects can be > tested @ https://www.ssllabs.com/ssltest/analyze.html?d=example.com by > pla

Re: SSLHonorCipherOrder for OpenBSD's httpd

2013-07-07 Thread Otto Moerbeek
On Sun, Jul 07, 2013 at 08:40:52PM -0700, Aaron Stellman wrote: > On Mon, Jul 08, 2013 at 05:30:22AM +0200, J??r??mie Courr??ges-Anglas wrote: > > Otto Moerbeek had already done work about this, but no one commented on > > the mailing-list: http://marc.info/?l=openbsd-tech&m=

Re: libc malloc poison

2013-07-04 Thread Otto Moerbeek
On Thu, Jul 04, 2013 at 05:24:20PM +0200, Mark Kettenis wrote: > > From: Theo de Raadt > > Date: Thu, 04 Jul 2013 09:04:54 -0600 > > > > I suspect the best approach would be a hybrid value. The upper half > > of the address should try to land in an unmapped zone, or into the zero > > page, or i

panic while resuming with connected ucom

2013-06-21 Thread Otto Moerbeek
Hi, I have a Thinkpad T430 with an internal 3G modem that shows up as a (couple of) umodem. If I have a connection to the corresponding ucom active (with cu or pppd) and suspend the machine followed by a resume, it panics (or rather gets a trap) during resume; hand typed: kernel: protection fault

Re: help X11 performance: make sigprocmask(2) SY_NOLOCK

2013-06-20 Thread Otto Moerbeek
On Wed, Jun 19, 2013 at 07:39:15PM +, Miod Vallat wrote: > > > > - p->p_sigmask = mask &~ sigcantmask; > > > > + p->p_sigmask = mask; > > > > On the right architecture where a word store isn't atomic enough and > > with the right compiler that decides to put p_sigm

Re: fsck vs fsck_ffs WHAT'S THE DIFFERENCE?

2013-06-18 Thread Otto Moerbeek
On Tue, Jun 18, 2013 at 11:09:20AM -0700, Matthew Dempsky wrote: > On Tue, Jun 18, 2013 at 11:04 AM, wrote: > > Please, What is the difference between 'fsck' and 'fsck_ffs' command? > > fsck detects the filesystem on disk and runs the appropriate > fsck_${FILESYSTEM} utility automatically. plu

Re: SOFTRAID PROBLEM

2013-06-16 Thread Otto Moerbeek
On Sun, Jun 16, 2013 at 07:57:48AM +0200, laborat...@cpnetserver.net wrote: > Hi, > after using some hard-drive with softraid in raid5, > I can no longer reset them. All disks the same problem... > When I try to delete raid partition disklabel reports: > With the command: > disklabel -E wd1, after

Re: dhcpd uses bad current time

2013-05-16 Thread Otto Moerbeek
On Wed, May 15, 2013 at 10:29:22AM +0200, Gerhard Roth wrote: > On Wed, 15 May 2013 10:15:54 +0200 > Gerhard Roth wrote: > > > In dhcpd, variable cur_time is set only once per dispatch loop. > > Unfortunately, this is done before the poll(2) call. Since poll(2) > > may sleep for an arbitrary amo

Re: dhcpd uses bad current time

2013-05-15 Thread Otto Moerbeek
On Wed, May 15, 2013 at 10:15:54AM +0200, Gerhard Roth wrote: > In dhcpd, variable cur_time is set only once per dispatch loop. > Unfortunately, this is done before the poll(2) call. Since poll(2) > may sleep for an arbitrary amount of time, the value of cur_time > might refer to some long ago poi

Re: realloc errno

2013-05-11 Thread Otto Moerbeek
On Tue, May 07, 2013 at 12:43:48AM -0400, Ted Unangst wrote: > If growing the current region fails, realloc will leave errno set, > even though the function will eventually succeed. (Late reply because I was away on vacation) I don't think this is correct. realloc itself already takes care of th

Re: DPI for pf(4)

2013-05-02 Thread Otto Moerbeek
fOn Thu, May 02, 2013 at 04:03:05PM +0200, Franco Fichtner wrote: > On May 2, 2013, at 3:20 PM, Damien Miller wrote: > > > On Thu, 2 May 2013, Franco Fichtner wrote: > > > >> OK, the implementation only pulls a couple of bytes from the packet's > >> payload. It will never pull bytes that are no

Re: rm(1) static addition

2013-04-27 Thread Otto Moerbeek
On Sat, Apr 27, 2013 at 09:09:25PM +0200, Franco Fichtner wrote: > On Apr 27, 2013, at 7:36 PM, Ted Unangst wrote: > > > On Sat, Apr 27, 2013 at 08:10, Otto Moerbeek wrote: > >> On Sat, Apr 27, 2013 at 01:08:06AM -0400, Eitan Adler wrote: > >> > >>>

Re: rm(1) static addition

2013-04-26 Thread Otto Moerbeek
On Sat, Apr 27, 2013 at 01:08:06AM -0400, Eitan Adler wrote: > Hey all, > > Time for attempt #2! > > Adding static to internal function allows the compiler to better > detect dead code (functions, variables, etc) and makes it easier for > the compiler to optimize; e.g., since it knows a function

base apache and HonorCipherOrder

2013-04-23 Thread Otto Moerbeek
Hi, SSLHonorCipherOrder is needed by some recommended setups to protect against the beast attack, but only available in newer apaches. So I added it to our apache in base. If there is any interest, I might add the manual stuff, get ok's and commit it. -Otto Index: src/modules/ssl/mod_s

Re: xor lists

2013-04-17 Thread Otto Moerbeek
On Wed, Apr 17, 2013 at 08:06:43PM -0400, Ted Unangst wrote: > At some point, every young programmer hears a story about how you can > use xor to store the pointers of a list. It's a stupid story for many > reasons, not least of which is the fact that nobody ever does this. > Sounds like a challen

Re: Mention available filesystem types for disklabel somewhere

2013-04-06 Thread Otto Moerbeek
On Sat, Apr 06, 2013 at 12:43:32PM -0500, Chris Bennett wrote: > On Sat, Apr 06, 2013 at 10:48:55AM -0600, Theo de Raadt wrote: > > > I had to search the sources to realise the fat filesystem type is called > > > MSDOS. Maybe at least a header can be mentioned in disklabel(8)? > > > > Sorry, ever

Re: nc(1) shutdown(2) typo

2013-03-20 Thread Otto Moerbeek
On Wed, Mar 20, 2013 at 12:43:37AM +, Creamy wrote: > On Tue, Mar 19, 2013 at 06:34:31PM -0600, Theo de Raadt wrote: > > > Using netcat to reliably get data is never going to be appropriate > > > for a production system, IMHO. > > > > Wow. You sure do set the bar low. Probably a lot of peop

Re: nc(1) shutdown(2) typo

2013-03-19 Thread Otto Moerbeek
On Tue, Mar 19, 2013 at 08:43:55PM +0100, J??r??mie Courr??ges-Anglas wrote: > Otto Moerbeek writes: > > > On Tue, Mar 19, 2013 at 03:16:50PM -0400, Ted Unangst wrote: > > > >> OK, thanks, I think I get it. Let me summarize: > >> > >> nc current

Re: nc(1) shutdown(2) typo

2013-03-19 Thread Otto Moerbeek
On Tue, Mar 19, 2013 at 08:12:15PM +0100, Martin Pelikan wrote: > > >> Yes, but it would even be better if there would be an option to get > > >> the shutdown on EOF behaviour back. > > >> > > >> Some servers wait until they see the shutdown from the client to finish > > >> their work. > > > > wo

Re: nc(1) shutdown(2) typo

2013-03-19 Thread Otto Moerbeek
On Tue, Mar 19, 2013 at 03:16:50PM -0400, Ted Unangst wrote: > OK, thanks, I think I get it. Let me summarize: > > nc currently calls shutdown() when it gets EOF on input. This is the > right thing to do, because that's how well written network clients > indicate end of input. Some broken servers

Re: nc(1) shutdown(2) typo

2013-03-19 Thread Otto Moerbeek
On Tue, Mar 19, 2013 at 07:48:41PM +0100, Otto Moerbeek wrote: > On Tue, Mar 19, 2013 at 02:35:49PM -0400, Ted Unangst wrote: > > > On Tue, Mar 19, 2013 at 17:39, Stuart Henderson wrote: > > > On 2013/03/19 18:26, Otto Moerbeek wrote: > > >> On Tue, Mar 19,

Re: nc(1) shutdown(2) typo

2013-03-19 Thread Otto Moerbeek
On Tue, Mar 19, 2013 at 02:35:49PM -0400, Ted Unangst wrote: > On Tue, Mar 19, 2013 at 17:39, Stuart Henderson wrote: > > On 2013/03/19 18:26, Otto Moerbeek wrote: > >> On Tue, Mar 19, 2013 at 04:00:46PM +0100, Martin Pelikan wrote: > >> > >> > > wf

Re: nc(1) shutdown(2) typo

2013-03-19 Thread Otto Moerbeek
On Tue, Mar 19, 2013 at 04:00:46PM +0100, Martin Pelikan wrote: > > wfd is stdin, so doing a shutdown on it will mostly be a noop, right? > > Of course you're right. I was so focused on finding the bug I didn't > look above what the fd is :-( > > Are you okay with removing this particular shutd

Re: nc(1) shutdown(2) typo

2013-03-18 Thread Otto Moerbeek
On Mon, Mar 18, 2013 at 03:14:59PM +0100, Martin Pelikan wrote: > Hi! > > Theo pointed out an issue with nc(1), as mentioned in > > https://groups.google.com/forum/?hl=en&fromgroups=#!topic/muc.lists.freebsd.bugs/0yNFZVHClcI > > and > > https://bugs.launchpad.net/ubuntu/+source/netcat-openbsd/

Re: less list_end macros

2013-03-08 Thread Otto Moerbeek
On Fri, Mar 08, 2013 at 10:14:02AM +0100, Mark Kettenis wrote: > > Date: Fri, 8 Mar 2013 09:55:07 +0100 > > From: Martin Pieuchot > > > > On 07/03/13(Thu) 22:32, Claudio Jeker wrote: > > > On Thu, Mar 07, 2013 at 04:23:34PM -0500, Ted Unangst wrote: > > > > Maybe I'm just easily confused, but wh

Re: add missing semicolon to tree(3) example code

2013-02-17 Thread Otto Moerbeek
On Mon, Feb 18, 2013 at 12:11:37AM +0100, Mark Kettenis wrote: > > Date: Sun, 17 Feb 2013 18:45:10 +0100 > > From: Otto Moerbeek > > > > On Sun, Feb 17, 2013 at 03:59:41PM +0100, Franco Fichtner wrote: > > > > > Hi all, > > > > > > foun

Re: add missing semicolon to tree(3) example code

2013-02-17 Thread Otto Moerbeek
On Sun, Feb 17, 2013 at 03:59:41PM +0100, Franco Fichtner wrote: > Hi all, > > found this still lingering in my tree. Still trying to figure out > the best workflow for sending patches. Not sure if this adheres > to the standards. > > Thanks, > Franco > --- > share/man/man3/tree.3 | 2 +- > 1 f

been playing wit logical domains on a Sun T1000

2013-01-23 Thread Otto Moerbeek
Hi, After seeing the undeadly article I got myself a Sun T1000 and have been playing with ldoms on it. I saw a few things: 1. Partitions cannot be used as backing store for ldom virtual disks, the VOP_GEATTR calls return size 0 for the raw device. I also wonder if other VOP call in vdsp(4) will w

Re: Small size_t patch for fsck_ffs

2012-12-26 Thread Otto Moerbeek
On Wed, Dec 26, 2012 at 08:58:19AM +0100, Otto Moerbeek wrote: > On Tue, Dec 25, 2012 at 02:02:01PM -0800, Philip Guenther wrote: > > > On Tue, Dec 25, 2012 at 6:55 AM, Vadim Zhukov wrote: > > > A small nit in fsck_ffs/dir.c. A few lines above (size_t) cast is > > &g

Re: Small size_t patch for fsck_ffs

2012-12-26 Thread Otto Moerbeek
On Tue, Dec 25, 2012 at 02:02:01PM -0800, Philip Guenther wrote: > On Tue, Dec 25, 2012 at 6:55 AM, Vadim Zhukov wrote: > > A small nit in fsck_ffs/dir.c. A few lines above (size_t) cast is > > used, but here it's missing. > ... > > - if (memcmp(dirp->d_name, idesc->id_name, (int)dirp->d_na

Re: [PATCH] mlockall() problem in OpenBSD 5.2

2012-12-08 Thread Otto Moerbeek
On Sun, Dec 09, 2012 at 08:28:08AM +0100, Otto Moerbeek wrote: > On Sun, Dec 09, 2012 at 12:26:35AM +0100, Ariane van der Steldt wrote: > > > On 11/09/12 08:56, Gerhard Roth wrote: > > >On Thu, 08 Nov 2012 16:22:41 -0500 > > >Ted Unangst wrote: > > >>O

Re: [PATCH] mlockall() problem in OpenBSD 5.2

2012-12-08 Thread Otto Moerbeek
On Sun, Dec 09, 2012 at 12:26:35AM +0100, Ariane van der Steldt wrote: > On 11/09/12 08:56, Gerhard Roth wrote: > >On Thu, 08 Nov 2012 16:22:41 -0500 > >Ted Unangst wrote: > >>On Thu, Nov 08, 2012 at 13:34, Ilya Bakulin wrote: > >> > >>>The problem seems to be in uvm_map_pageable_all() function >

Re: rs(1) segmentation fault fix

2012-12-03 Thread Otto Moerbeek
On Mon, Dec 03, 2012 at 08:48:46PM +0200, Arto Jonsson wrote: > Hi, > > noticed this on -current (dated Dec 2) amd64: > > $ who | rs > Segmentation fault (core dumped) > > $ jot -r 100 | rs 10 10 > Segmentation fault (core dumped) > > I traced it to v1.10 of rs.c: > http://www.

Re: Make cron supply valid RFC822 From: and To: headers

2012-11-13 Thread Otto Moerbeek
On Tue, Nov 13, 2012 at 03:14:06PM +0100, Alexander Hall wrote: > On 11/13/12 13:49, Christian Weisgerber wrote: > >Alexander Hall wrote: > > > >>Since I switched to SMTPD I noticed a few cron emails being marked as > >>spam by spamassassin, largely caused by the From: and To: headers not > >>con

Re: dc(1) exp improvements

2012-11-06 Thread Otto Moerbeek
On Tue, Nov 06, 2012 at 04:57:20PM -0430, Andres Perera wrote: > On Tue, Nov 6, 2012 at 3:27 PM, Otto Moerbeek wrote: > > Hi, > > > > And here's a diff to repair ^, whcih now produces correct results for > > things like > > > > (dc)0.1 _1 ^p >

dc(1) exp improvements

2012-11-06 Thread Otto Moerbeek
Hi, And here's a diff to repair ^, whcih now produces correct results for things like (dc)0.1 _1 ^p or (bc)0.1 ^ -1 The diff is against very current, so beware. Please test. I have some regress test updates for dc as well. t9 turns out to be a wrong test (computation of 2.1 ^ 500). Th

Re: remove redundant information from mmap.2

2012-10-17 Thread Otto Moerbeek
On Wed, Oct 17, 2012 at 03:14:14PM +0100, Jason McIntyre wrote: > On Wed, Oct 17, 2012 at 09:06:23AM +0200, Otto Moerbeek wrote: > > > > Op 16 okt. 2012 om 22:56 heeft Jason McIntyre het > > volgende geschreven: > > > > > On Sat, Oct 06, 2012 at 09:40:23

Re: remove redundant information from mmap.2

2012-10-17 Thread Otto Moerbeek
Op 16 okt. 2012 om 22:56 heeft Jason McIntyre het volgende geschreven: > On Sat, Oct 06, 2012 at 09:40:23PM +0200, Dawe wrote: >> I think this information is already given in the sentences before. >> >> Index: mmap.2 >> === >> RCS fi

Re: Scheduler improvements, take 1001, Patch 2/5

2012-10-15 Thread Otto Moerbeek
On Mon, Oct 15, 2012 at 04:01:29PM +0100, Stuart Henderson wrote: > On 2012/10/15 16:18, David Coppa wrote: > > On Sun, Oct 14, 2012 at 4:53 PM, Gregor Best wrote: > > > On Sun, Oct 14, 2012 at 11:05:36AM +0200, David Coppa wrote: > > >> On Tue, Oct 9, 2012 at 6:21 PM, Gregor Best wrote: > > >>

Re: make mg statusline a bit more informative

2012-10-10 Thread Otto Moerbeek
On Wed, Oct 10, 2012 at 03:39:39PM +0200, Jasper Lievisse Adriaanse wrote: > On Wed, Oct 10, 2012 at 03:31:30PM +0200, Mark Kettenis wrote: > > > Date: Wed, 10 Oct 2012 15:12:59 +0200 > > > From: Jasper Lievisse Adriaanse > > > > > > Currently the statusline in mg shows the line and column numbe

Re: Threads related SIGSEGV in random.c

2012-09-20 Thread Otto Moerbeek
On Thu, Sep 20, 2012 at 09:42:16AM +0100, Stuart Henderson wrote: > On 2012/09/19 22:06, Stefan Sperling wrote: > > On Wed, Sep 19, 2012 at 10:37:09PM +0300, Alexey Suslikov wrote: > > > Could you guide me how to rebuild/reinstall libc in a proper way? > > > > It's easy, just needs 11 steps. This

<    2   3   4   5   6   7   8   9   10   >