Re: multi-pool malloc wip diff

2016-08-23 Thread Otto Moerbeek
On Mon, Aug 22, 2016 at 08:59:44PM -0400, Ted Unangst wrote: > Otto Moerbeek wrote: > > > > After a forkl of a threaded program __isthreaded is reset, but > > existing allocations are spread around the pools. But the new single > > threaded child only looks in the firs

Re: multi-pool malloc wip diff

2016-08-22 Thread Otto Moerbeek
On Mon, Aug 22, 2016 at 08:37:30PM +0200, Otto Moerbeek wrote: > On Mon, Aug 22, 2016 at 07:35:49PM +0200, Otto Moerbeek wrote: > > > On Mon, Aug 22, 2016 at 07:07:21PM +0200, Gregor Best wrote: > > > > > On Mon, Aug 22, 2016 at 05:03:34PM +0200, Otto Moerbeek wr

Re: multi-pool malloc wip diff

2016-08-22 Thread Otto Moerbeek
On Mon, Aug 22, 2016 at 07:07:21PM +0200, Gregor Best wrote: > On Mon, Aug 22, 2016 at 05:03:34PM +0200, Otto Moerbeek wrote: > > On Mon, Aug 22, 2016 at 05:00:12PM +0200, Otto Moerbeek wrote: > > > > > Hmm, indeed, looking into it. > > > > Fixed diff now

Re: multi-pool malloc wip diff

2016-08-22 Thread Otto Moerbeek
On Mon, Aug 22, 2016 at 05:00:12PM +0200, Otto Moerbeek wrote: > Hmm, indeed, looking into it. Fixed diff now online, -Otto

Re: multi-pool malloc wip diff

2016-08-22 Thread Otto Moerbeek
On Mon, Aug 22, 2016 at 04:15:16PM +0200, Gregor Best wrote: > Hi, > > On Mon, Aug 22, 2016 at 08:21:08AM +0200, Otto Moerbeek wrote: > > [...] > > New diff posted in http://www.drijf.net/openbsd/malloc. > > > > The intention is that this is close to commitabl

Re: multi-pool malloc wip diff

2016-08-22 Thread Otto Moerbeek
On Wed, May 11, 2016 at 10:04:48AM +0200, Otto Moerbeek wrote: > On Fri, Apr 29, 2016 at 08:42:00AM +0200, Otto Moerbeek wrote: > > > Hi, > > > > new diff in http://www.drijf.net/openbsd/malloc/ > > > > Should fix the issue Ted spotted and contains init

Re: malloc.conf: better docs and impl for J/J

2016-07-05 Thread Otto Moerbeek
On Sun, Jul 03, 2016 at 09:31:11AM +0200, Otto Moerbeek wrote: > On Sat, Jul 02, 2016 at 01:17:10PM -0400, Ted Unangst wrote: > > > Otto Moerbeek wrote: > > > Hi, > > > > > > J/j is actually a three valued var. So document that and make it > >

Re: malloc.conf: better docs and impl for J/J

2016-07-03 Thread Otto Moerbeek
On Sat, Jul 02, 2016 at 01:17:10PM -0400, Ted Unangst wrote: > Otto Moerbeek wrote: > > Hi, > > > > J/j is actually a three valued var. So document that and make it > > possible to set all three values. Default is still 1. > > I initially left the default

malloc.conf: better docs and impl for J/J

2016-07-02 Thread Otto Moerbeek
Hi, J/j is actually a three valued var. So document that and make it possible to set all three values. Default is still 1. -Otto Index: share/man/man5/malloc.conf.5 === RCS file: /cvs/src/share/man/man5/malloc.conf.5,v

Re: pf.conf macro with space

2016-06-21 Thread Otto Moerbeek
On Tue, Jun 21, 2016 at 01:11:16PM +0200, Henning Brauer wrote: > * Stefan Sperling [2016-06-21 11:15]: > > Generally, I would appreciate more detailed error messages from the pf.conf > > parser. I recall several occasions where pfctl threw "syntax error" and more > > specific

Re: Not enough inodes on /usr for ports/xenocara

2016-06-14 Thread Otto Moerbeek
On Tue, Jun 14, 2016 at 06:14:05PM +0200, Jeremie Courreges-Anglas wrote: > Marc Peters writes: > > > Hi, > > > > i just did an installation of a HP DL360 Gen9 to test UEFI installations > > with 5.9. I just accepted most of the defaults and did this for the > > disklabels,

Re: Not enough inodes on /usr for ports/xenocara

2016-06-14 Thread Otto Moerbeek
On Tue, Jun 14, 2016 at 03:41:11PM +0200, Marc Peters wrote: > Hi, > > i just did an installation of a HP DL360 Gen9 to test UEFI installations > with 5.9. I just accepted most of the defaults and did this for the > disklabels, too. I wanted to checkout the sources to do release builds, > but

Re: Not enough inodes on /usr for ports/xenocara

2016-06-14 Thread Otto Moerbeek
On Tue, Jun 14, 2016 at 06:14:05PM +0200, Jeremie Courreges-Anglas wrote: > Marc Peters writes: > > > Hi, > > > > i just did an installation of a HP DL360 Gen9 to test UEFI installations > > with 5.9. I just accepted most of the defaults and did this for the > > disklabels,

Re: malloc: add full delayed chunk double-free detection

2016-05-11 Thread Otto Moerbeek
On Tue, May 10, 2016 at 07:14:41PM -0400, Daniel Micay wrote: > > Seems valuable. Note, though, that you're developing on top of the > > multi-pool malloc patches: > > > > https://marc.info/?t=14587167622=1=2 > > > > http://www.drijf.net/openbsd/malloc/ > > > > So there are probably

Re: malloc: fix setting errno on out-of-memory

2016-05-10 Thread Otto Moerbeek
On Tue, May 10, 2016 at 02:48:18PM -0400, Daniel Micay wrote: > The ENOMEM errno wasn't being set in some code paths where it was gated > behind mopts.malloc_xmalloc: Called functions do set errno..., you're effectively overriding those. Which means those can go if this is applied. This needs

Re: static in ze kernel

2016-04-29 Thread Otto Moerbeek
On Fri, Apr 29, 2016 at 08:54:51AM +0200, Otto Moerbeek wrote: > On Fri, Apr 29, 2016 at 04:43:56PM +1000, David Gwynne wrote: > > > > > > On 28 Apr 2016, at 22:49, Mark Kettenis <mark.kette...@xs4all.nl> wrote: > > > > > >> Date: Thu, 28 Apr 201

Re: static in ze kernel

2016-04-29 Thread Otto Moerbeek
On Fri, Apr 29, 2016 at 04:43:56PM +1000, David Gwynne wrote: > > > On 28 Apr 2016, at 22:49, Mark Kettenis wrote: > > > >> Date: Thu, 28 Apr 2016 13:50:53 +0200 > >> From: Martin Pieuchot > >> > >> The reason why we do not use 'static' in the

Re: multi-pool malloc wip diff

2016-04-29 Thread Otto Moerbeek
Hi, new diff in http://www.drijf.net/openbsd/malloc/ Should fix the issue Ted spotted and contains initial code to only set up multiple pools if threaded. This one is only lightly tested by me, but I wanted to post this before I'll be away for a semi-long weekend, I don't think this is ready

Re: multi-pool malloc wip diff

2016-04-28 Thread Otto Moerbeek
On Thu, Apr 28, 2016 at 01:07:30PM -0400, Ted Unangst wrote: > Otto Moerbeek wrote: > > static void > > -ofree(struct dir_info *pool, void *p) > > +ofree(struct dir_info *argpool, void *p) > > { > > + struct dir_info *pool; > > struct region_in

Re: multi-pool malloc wip diff

2016-04-07 Thread Otto Moerbeek
On Wed, Mar 30, 2016 at 06:30:53PM +0200, Norman Golisz wrote: > On Mon Mar 28 2016 11:27, Otto Moerbeek wrote: > > Second diff. Only one person (Stefan Kempf, thanks!) gave feedback... > > Sorry, running with this patch since a week, but missed to give > feedback. >

Re: bug in grep

2016-04-03 Thread Otto Moerbeek
On Sun, Apr 03, 2016 at 10:31:33AM +0200, Martin Natano wrote: > On Sun, Apr 03, 2016 at 09:14:40AM +0200, Otto Moerbeek wrote: > > On Sat, Apr 02, 2016 at 09:13:20PM +, H??ctor Luis Gimbatti wrote: > > > > > Hi, > > > Apparently the error seems to be in /us

Re: bug in grep

2016-04-03 Thread Otto Moerbeek
On Sat, Apr 02, 2016 at 09:13:20PM +, H??ctor Luis Gimbatti wrote: > Hi, > Apparently the error seems to be in /usr/src/usr.bin/grep/util.c at line 400: > > if ((!(lflag || cflag)) && ((!(bol || eol)) && > ((lastHalfDot) && ((firstHalfDot < 0) || >

Re: [patch] ftpd: no pid_t to long cast

2016-04-02 Thread Otto Moerbeek
On Sat, Apr 02, 2016 at 05:32:02PM +0200, frit...@alokat.org wrote: > Is it really necessary to cast pid_t values to long, only > for printing? yes, pid_t may be long, as defined by posix, -Otto > > --f. > > > Index: ftpd.c >

Re: multi-pool malloc wip diff

2016-03-28 Thread Otto Moerbeek
On Mon, Mar 28, 2016 at 11:43:22AM +0200, Otto Moerbeek wrote: > No specifics, just watch out for malloc related bugs. It's > both important that non-threaded programs and non-threaded programs > show no new bugs. And don't forget to test non-threaded programs ;-)

Re: multi-pool malloc wip diff

2016-03-28 Thread Otto Moerbeek
On Mon, Mar 28, 2016 at 03:40:21AM -0600, Abel Abraham Camarillo Ojeda wrote: > On Mon, Mar 28, 2016 at 3:27 AM, Otto Moerbeek <o...@drijf.net> wrote: > > On Wed, Mar 23, 2016 at 08:00:19AM +0100, Otto Moerbeek wrote: > > > >> Hi, > >> > >>

Re: multi-pool malloc wip diff

2016-03-28 Thread Otto Moerbeek
On Wed, Mar 23, 2016 at 08:00:19AM +0100, Otto Moerbeek wrote: > Hi, > > first diff that seems to work. Tested on amd64 and compile tested on > sparc64. > > It is alo available at http://www.drijf.net/openbsd/malloc > > Form the README: > > The diff should be

multi-pool malloc wip diff

2016-03-23 Thread Otto Moerbeek
stdlib/malloc.c21 Mar 2016 16:34:52 - @@ -1,6 +1,6 @@ /* $OpenBSD: malloc.c,v 1.185 2016/03/17 17:55:33 mmcc Exp $ */ /* - * Copyright (c) 2008, 2010, 2011 Otto Moerbeek <o...@drijf.net> + * Copyright (c) 2008, 2010, 2011, 2016 Otto Moerbeek <o...@drijf.net> *

Re: malloc: 1st small step in long way to multiple pools

2016-03-15 Thread Otto Moerbeek
On Tue, Mar 15, 2016 at 10:22:23PM +0100, Norman Golisz wrote: > Hi Otto, > > On Wed Mar 9 2016 10:06, Otto Moerbeek wrote: > > Lightly tested by myself on amd64, you can help by reviewing and > > testing this. > > I also don't see regressions on my amd64 -

Re: malloc: 1st small step in long way to multiple pools

2016-03-11 Thread Otto Moerbeek
On Fri, Mar 11, 2016 at 01:43:09PM +0100, Martin Pieuchot wrote: > On 09/03/16(Wed) 10:06, Otto Moerbeek wrote: > > a future goal for malloc is to use multiple pools in threaded environments, > > to reduce lock contention. > > > > This is a small first step towards

Re: malloc: 1st small step in long way to multiple pools

2016-03-11 Thread Otto Moerbeek
On Thu, Mar 10, 2016 at 10:31:17PM -0800, Michael McConville wrote: > Otto Moerbeek wrote: > > a future goal for malloc is to use multiple pools in threaded > > environments, to reduce lock contention. > > > > This is a small first step towards that goal: move

malloc: 1st small step in long way to multiple pools

2016-03-09 Thread Otto Moerbeek
Hi, a future goal for malloc is to use multiple pools in threaded environments, to reduce lock contention. This is a small first step towards that goal: move two globals to the pool-specific struct dir_info. Currently there's only a single pool, but that will change one day. Lightly tested by

Re: ksh: variable substitution in double quoted string

2016-03-03 Thread Otto Moerbeek
On Thu, Mar 03, 2016 at 07:14:43AM +0100, Dmitrij D. Czarkoff wrote: > Bob Beck said: > > This now starts to sounds sane, although the regress test needs to be > > named like paren-expansion-quotes not xxx-what-do-you-call this... > > The test my previous diff failed was

Re: pax name_split() error

2016-02-12 Thread Otto Moerbeek
On Fri, Feb 12, 2016 at 11:48:11PM -0500, Peter Bisroev wrote: > Dear Developers, > > I believe there is an issue with pax when it tries to archive path names that > are exactly 101 bytes long and start with a slash. For example (sorry for > long lines) > > $ pax -x ustar -w -f ./test.tar >

Re: Ntpd log message readably tweak.

2016-02-08 Thread Otto Moerbeek
On Sun, Feb 07, 2016 at 02:18:46PM +, Gerald Hanuer wrote: > Hello tech@, > > https://marc.info/?l=openbsd-misc=145479483809799=2 > > ntpd[9279]: adjusting local clock by 9.096751s > > ntpd[9279]: adjusting local clock by 7.971861s > > ntpd[9279]: adjusting local clock by 6.838999s > >

Re: Overflowable int -> size_t in grep

2015-12-07 Thread Otto Moerbeek
On Mon, Dec 07, 2015 at 02:32:50AM -0500, Michael McConville wrote: > Otto Moerbeek wrote: > > On Mon, Dec 07, 2015 at 01:36:22AM -0500, Michael McConville wrote: > > > This isn't a grave issue, but I came across it while exploring integer > > > overflow a

Re: Overflowable int -> size_t in grep

2015-12-06 Thread Otto Moerbeek
On Mon, Dec 07, 2015 at 01:36:22AM -0500, Michael McConville wrote: > This isn't a grave issue, but I came across it while exploring integer > overflow and think it's worth sharing. > > grep represents line numbers with an int, which predictably overflows > for inputs with >= 2^31 newlines. This

Re: Memory corruptions in bc(1)

2015-11-20 Thread Otto Moerbeek
On Thu, Nov 19, 2015 at 05:52:39PM -0500, Michael McConville wrote: > I'm already cache-thrashing with all of my side projects, so if anyone's > interested I'll leave this to them. > > A few days ago, I wanted to try American Fuzzy Lop (afl), and bc(1) > seemed like a good first target: it

Re: Memory corruptions in bc(1)

2015-11-20 Thread Otto Moerbeek
On Fri, Nov 20, 2015 at 11:52:16AM +0100, Otto Moerbeek wrote: > On Thu, Nov 19, 2015 at 05:52:39PM -0500, Michael McConville wrote: > > > I'm already cache-thrashing with all of my side projects, so if anyone's > > interested I'll leave this to them. > > > > A

Re: Signed indexing in bc(1)

2015-11-16 Thread Otto Moerbeek
On Mon, Nov 16, 2015 at 12:45:08PM -0500, Michael McConville wrote: > I may be missing something obvious here, but it seems that the below > indices should be unsigned. str_table has UCHAR_MAX elements, so it > expects to be indexed by chars > 127. > > I'm currently digging through a bunch of

Re: MALLOC_STATS and pledge

2015-11-13 Thread Otto Moerbeek
On Fri, Nov 13, 2015 at 09:11:46AM +, David CARLIER wrote: > Hi all, > > I ve tried to discuss this point with Otto Moerbeek but he might be > very busy so I throw the topic here if you do not mind ... > > I have the habit to enable MALLOC_STATS but with the recent pled

sasyncd exits at rc time

2015-11-11 Thread Otto Moerbeek
Hi, since i upgraded two pairs of firewalls to 5.8 I'm seeing that sasyncd exits at rc time if it find the carp interface link state to be "invalid". Changes in the carp interface code (sys/netinet/ip_carp.c 1.257) cause the interface to be in invalid state for a while at boot. This diff makes

Re: enhanced use-after-free detection for malloc v2

2015-11-01 Thread Otto Moerbeek
On Fri, Oct 30, 2015 at 11:51:17PM -0400, Daniel Micay wrote: > On 26/10/15 04:19 PM, Daniel Micay wrote: > > This is an improved revision of my earlier patch. > > > > It now validates the junk data in the delayed_chunks array in an atexit > > handler > > too, rather than just when allocations

Re: queue.3: missing curly bracket

2015-10-10 Thread Otto Moerbeek
On Sat, Oct 10, 2015 at 02:55:34PM +0200, Tobias Stoeckmann wrote: > That's what I get for copy out of a manual... > > The LIST_EMPTY example lacks an opening curly bracket. The other > examples have it, so it's a pretty obvious fix. ok, -Otto > > > Index: queue.3 >

Re: Drop a distracting function from locate(1)

2015-09-20 Thread Otto Moerbeek
On Sat, Sep 19, 2015 at 05:57:23PM -0400, Michael McConville wrote: > > What's your thinking behind this? To me this seems like a perfectly > > rational and well motivated function to have, both for readability and > > rather than having to repeat the same statements several times over in > > the

Re: Drop a distracting function from locate(1)

2015-09-20 Thread Otto Moerbeek
On Sun, Sep 20, 2015 at 07:43:46AM -0400, Michael McConville wrote: > Otto Moerbeek wrote: > > I do not agree. You only have to remeber "that function does sensible > > error checking" and you do not have to remember at each spot which > > condition is t

Re: Merge a stub file in ps(1)

2015-09-17 Thread Otto Moerbeek
On Wed, Sep 16, 2015 at 10:36:57PM -0400, Michael McConville wrote: > Michael McConville wrote: > > fmt.c contains two functions that are only called by command() in > > print.c. One of them is tiny, too. It seems simpler to have them in > > print.c as statics. > > I forgot to mention that I

Re: Multiple cmsghdrs in msghdr

2015-04-15 Thread Otto Moerbeek
Always fun, cmsg structures. Anyway, I'll try to find some info on this (maybe Stevens has something to say here). But your experiments indicate that various Unixes do not agree, so it's probably better to avoid sending multiple cmsg structures. Or there is a subtle error in the way you build

Re: Multiple cmsghdrs in msghdr

2015-04-15 Thread Otto Moerbeek
On Wed, Apr 15, 2015 at 11:32:11AM +0200, Mark Kettenis wrote: Date: Tue, 14 Apr 2015 21:26:25 -0400 From: William Orr w...@worrbase.com Hey, I was debugging a few CPython test failures yesterday, and I noticed that attaching multiple cmsg structures causes unp_internalize to

Re: sort output file permissions

2015-03-30 Thread Otto Moerbeek
On Sun, Mar 29, 2015 at 09:50:48PM +0200, Alexander Bluhm wrote: Hi, While doing make makesum in the ports framework, I realized that the distinfo file always gets permissions 0600. It uses sort -o in a way that the output file will overwrite the input file. In this case, sort creates a

Re: sort output file permissions

2015-03-30 Thread Otto Moerbeek
On Mon, Mar 30, 2015 at 04:48:55PM +0200, Alexander Bluhm wrote: On Mon, Mar 30, 2015 at 08:59:16AM +0200, Otto Moerbeek wrote: If you call umask(2), it's better to reset it to the old value after you're done. I reset the umask immediately after reading it. I only need the current

Re: New (4th March 2015) snapshot's installer - bsd.rd

2015-03-05 Thread Otto Moerbeek
On Thu, Mar 05, 2015 at 10:00:00AM +, Raf Czlonka wrote: Hi all, Just a heads up as I'm sure you had already spotted it. Newest (4th March 2015) snapshot's installer (bsd.rd) defaults to: pub/OpenBSD/5.7/$(machine) instead of: pub/OpenBSD/snapshots/$(machine) when

Re: New (4th March 2015) snapshot's installer - bsd.rd

2015-03-05 Thread Otto Moerbeek
On Thu, Mar 05, 2015 at 10:40:06AM +, Raf Czlonka wrote: On Thu, Mar 05, 2015 at 10:06:43AM GMT, Otto Moerbeek wrote: That's not an error, we are in the timeframe that releases are built. That means that the snaps are build using release settings. After the release has been cut

Re: unbound problem in 5.6

2015-02-16 Thread Otto Moerbeek
On Tue, Feb 17, 2015 at 12:45:47AM +, Stuart Henderson wrote: In gmane.os.openbsd.misc, Otto wrote: On Tue, Dec 30, 2014 at 11:09:44AM -0200, Raimundo Santos wrote: Hello misc@! I have a router (peaking at 70Mbps of aggregated traffic) that acts as a recursive internal DNS

Re: disk quotas bug fix [was: quotas grace period none right away]

2015-01-04 Thread Otto Moerbeek
On Sat, Jan 03, 2015 at 06:18:03PM -0600, Boris Goldberg wrote: Hello Otto, Friday, January 2, 2015, 4:16:50 PM, you wrote: OM On Fri, Jan 02, 2015 at 03:28:46PM -0600, Boris Goldberg wrote: What about our second patch? OM I'd rather stay in line with FreeBSD and document

Re: disk quotas bug fix [was: quotas grace period none right away]

2015-01-02 Thread Otto Moerbeek
On Tue, Dec 30, 2014 at 02:37:58PM -0600, Boris Goldberg wrote: Hello tech, Is there a particular reason why that path hasn't been committed? It's not in the cvs tree and the bug is reproducible on the latest snapshot. It's the first patch we are trying to commit and we might not

Re: disk quotas bug fix [was: quotas grace period none right away]

2015-01-02 Thread Otto Moerbeek
On Fri, Jan 02, 2015 at 03:28:46PM -0600, Boris Goldberg wrote: What about our second patch? I'd rather stay in line with FreeBSD and document quoaoff/quotaon is needed for the new grace period to take effect.

Re: disk quotas bug fix [was: quotas grace period none right away]

2015-01-02 Thread Otto Moerbeek
On Fri, Jan 02, 2015 at 02:32:39PM -0800, Philip Guenther wrote: On Fri, Jan 2, 2015 at 1:28 PM, Boris Goldberg bo...@twopoint.com wrote: Philip is right. It's embarrassing I haven't checked the case with hard quota myself. We'll look into it. Philip is actually suggesting the way. I

Re: disk quotas bug fix [was: quotas grace period none right away]

2014-12-30 Thread Otto Moerbeek
On Tue, Dec 30, 2014 at 02:37:58PM -0600, Boris Goldberg wrote: Hello tech, Is there a particular reason why that path hasn't been committed? It's not in the cvs tree and the bug is reproducible on the latest snapshot. It's the first patch we are trying to commit and we might not

Re: unnbound vs file descriptors

2014-12-16 Thread Otto Moerbeek
it does not document setting the login class in the pwd db is needed. -Otto /Bogdan On Tuesday, December 16, 2014 9:46 AM, Otto Moerbeek o...@drijf.net wrote: Hi, So i have started using unbound on a mailserver (running amd64 5.6-stable). First observation

Re: unnbound vs file descriptors

2014-12-16 Thread Otto Moerbeek
On Tue, Dec 16, 2014 at 10:30:21AM +0100, Antoine Jacoutot wrote: may just a naive question.. but did you sudo vipw and put unbound class for unbound user? That's not neccesary anymore these days, I believe. The rc.d subsystem takes case of setting the proper class, if available.

Re: avoid kdump crash on localtime() failure

2014-12-15 Thread Otto Moerbeek
On Tue, Dec 16, 2014 at 01:04:05AM +1100, Jonathan Gray wrote: So now time is printed by default afl has found that time_t values such as -9223372035438150153 will cause localtime() to fail and return NULL. strftime() can't deal with this and will at some point dereference tm without

Re: avoid kdump crash on localtime() failure

2014-12-15 Thread Otto Moerbeek
On Mon, Dec 15, 2014 at 03:21:24PM +0100, Otto Moerbeek wrote: On Tue, Dec 16, 2014 at 01:04:05AM +1100, Jonathan Gray wrote: So now time is printed by default afl has found that time_t values such as -9223372035438150153 will cause localtime() to fail and return NULL. strftime() can't

unnbound vs file descriptors

2014-12-15 Thread Otto Moerbeek
Hi, So i have started using unbound on a mailserver (running amd64 5.6-stable). First observation is that it uses (too?) many file descriptors in the default setup. Dec 15 22:38:00 mx1 unbound: [8713:0] error: can't create socket: Too many open files Dec 15 22:38:00 mx1 last message repeated

Re: disk quotas bug fix [was: quotas grace period none right away]

2014-12-02 Thread Otto Moerbeek
On Mon, Dec 01, 2014 at 09:52:18PM -0600, Boris Goldberg wrote: Hello misc, I've reported a detailed bug two months ago. The short story - grace period end time isn't being reset if the over_soft_quota stage is reached by chown command. I've confirmed it on i386 5.0 through current (as of

Re: disk quotas bug fix [was: quotas grace period none right away]

2014-12-02 Thread Otto Moerbeek
On Tue, Dec 02, 2014 at 07:47:01AM -0600, Boris Goldberg wrote: Hello Otto, Tuesday, December 2, 2014, 2:14:11 AM, you wrote: OM Cool, but your mailer mangled the diff. Here it is for current. Thanks. How was it mangled? Looks fine in the Daily digest. I wanted to attach a text

Re: disk quotas bug fix [was: quotas grace period none right away]

2014-12-02 Thread Otto Moerbeek
On Tue, Dec 02, 2014 at 01:03:53PM -0500, Ted Unangst wrote: On Tue, Dec 02, 2014 at 07:47, Boris Goldberg wrote: Hello Otto, Tuesday, December 2, 2014, 2:14:11 AM, you wrote: OM Cool, but your mailer mangled the diff. Here it is for current. Thanks. How was it mangled? Looks

Re: memcpy abort: xsane

2014-12-01 Thread Otto Moerbeek
On Mon, Dec 01, 2014 at 10:24:33AM +, Stuart Henderson wrote: ports/graphics/xsane crashes at startup with an overlapping memcpy. However all it is doing here is an snprintf. Any ideas? Could the problem be in snprintf rather than xsane? (gdb) r Starting program: /usr/local/bin/xsane

Re: yacc: remove dead stores and use __dead

2014-12-01 Thread Otto Moerbeek
On Mon, Dec 01, 2014 at 09:52:31AM -0700, Todd C. Miller wrote: There were two dead stores found by the llvm analyzer (the value is overwritten before it is read). I've also marked functions calling done() __dead to avoid false positives. There are two more warnings from the analyzer but

Re: [patch]rcs: comment typo

2014-11-30 Thread Otto Moerbeek
On Sat, Nov 29, 2014 at 05:14:08PM +0100, Fritjof Bornebusch wrote: On Sat, Nov 29, 2014 at 04:53:28PM +0100, Otto Moerbeek wrote: On Sat, Nov 29, 2014 at 02:22:25PM +0100, Fritjof Bornebusch wrote: Hi tech, it's NULL not NUL. You're touching a big controversy here. Many

Re: [patch]rcs: comment typo

2014-11-29 Thread Otto Moerbeek
On Sat, Nov 29, 2014 at 02:22:25PM +0100, Fritjof Bornebusch wrote: Hi tech, it's NULL not NUL. You're touching a big controversy here. Many developers say that NUL is the right term when rferring to chars and not pointers, -Otto fritjof Index: diff3.c

Re: [Patch]rcs: use rcsnum_cmp

2014-11-28 Thread Otto Moerbeek
On Sun, Nov 23, 2014 at 05:19:16PM +0100, Fritjof Bornebusch wrote: Hi tech, like the XXX comment says, rcsnum_cmp() can be used instead of a *for* loop. The following shows the original behavior: $ co -r1.2 foo.txt,v foo.txt,v -- foo.txt revision 1.2 done $ co -r1.1 foo.txt,v

Re: patch: add regression tests

2014-11-25 Thread Otto Moerbeek
On Tue, Nov 25, 2014 at 04:34:25PM +0100, Tobias Stoeckmann wrote: Hi, the regress tests for patch only cover unified diffs so far. I guess nobody minds if I add 3 tests for: - normal diff - context diff - ed diff regress does not need oks, just add stuff if you think it makes sense

Re: patch: correct double-free in dc(1)

2014-11-24 Thread Otto Moerbeek
On Mon, Nov 24, 2014 at 01:38:40PM +0100, S??bastien Marie wrote: Hi, Starting to play with afl-fuzz, I test it with dc(1), and it found a Bus error. Basically: $ echo '1 2:x1Lx1:x1:x' | dc Bus error (core dumped) I traced the bug, and the code before do a double-free (resulting the

Re: patch: correct double-free in dc(1)

2014-11-24 Thread Otto Moerbeek
On Mon, Nov 24, 2014 at 01:38:40PM +0100, S??bastien Marie wrote: Hi, Starting to play with afl-fuzz, I test it with dc(1), and it found a Bus error. Basically: $ echo '1 2:x1Lx1:x1:x' | dc Bus error (core dumped) I traced the bug, and the code before do a double-free (resulting the

Re: patch: avoid reading after end of string

2014-11-18 Thread Otto Moerbeek
Hi, I seem to remember other code guarantees that lines are always termined by '\n'. Specifically plan_a(), plan_b() and ifetch(); -Otto On Tue, Nov 18, 2014 at 03:27:27PM +0100, Tobias Stoeckmann wrote: Hi, on a diff with a missing new line, it is possible that patch will read

Re: patch: avoid reading after end of string

2014-11-18 Thread Otto Moerbeek
On Tue, Nov 18, 2014 at 04:41:52PM +0100, Tobias Stoeckmann wrote: On Tue, Nov 18, 2014 at 04:32:17PM +0100, Otto Moerbeek wrote: I seem to remember other code guarantees that lines are always termined by '\n'. Specifically plan_a(), plan_b() and ifetch(); Not in this case. We use

Re: On this -lightly loaded- machine a second lasts two or three seconds

2014-10-28 Thread Otto Moerbeek
On Tue, Oct 28, 2014 at 04:42:55AM -0600, Abel Abraham Camarillo Ojeda wrote: $ while sleep 1; do date; done Tue Oct 28 04:34:04 CST 2014 Tue Oct 28 04:34:06 CST 2014 Tue Oct 28 04:34:08 CST 2014 Tue Oct 28 04:34:11 CST 2014 Tue Oct 28 04:34:13 CST 2014 Tue Oct 28 04:34:15 CST 2014 Tue

Re: [patch]lock and unlock like GnuRCS

2014-10-07 Thread Otto Moerbeek
to happen then better to match -l -u like Fritjof's diff. On Fri, Oct 03, 2014 at 12:55:35PM +0200, Otto Moerbeek wrote: On Thu, Oct 02, 2014 at 12:56:10AM +0100, Nicholas Marriott wrote: OTOH, check out what we do with rcs -L and -U... I kinda like that, because it tells you

Re: [patch]lock and unlock like GnuRCS

2014-10-07 Thread Otto Moerbeek
On Tue, Oct 07, 2014 at 02:56:07PM +0200, Fritjof Bornebusch wrote: On Tue, Oct 07, 2014 at 09:34:33AM +0200, Otto Moerbeek wrote: On Tue, Oct 07, 2014 at 03:10:44AM -0400, Daniel Dickman wrote: Fritjof, have you let the gnu rcs project know about the segfault? Maybe see how

Re: [patch]lock and unlock like GnuRCS

2014-10-01 Thread Otto Moerbeek
On Wed, Oct 01, 2014 at 07:58:16PM -0700, Philip Guenther wrote: On Wed, Oct 1, 2014 at 4:41 PM, Daniel Dickman didick...@gmail.com wrote: posix commands (like ls(1) for example) keep the last option when mutually exclusive options are specified. does it make sense to keep rcs consistent

Re: [Patch] use exit() directly in usage()

2014-10-01 Thread Otto Moerbeek
On Wed, Oct 01, 2014 at 05:41:11PM -0500, Kent R. Spillner wrote: ok kspillner@. It would be nice to replace some of those exit(1) with exit(EXIT_FAILURE), but that should be a separate diff that also updates the err/errx's as well. In general EXIT_XXX is frowned upon in OpenBSD.

Re: [Patch] use exit() directly in usage()

2014-09-30 Thread Otto Moerbeek
On Tue, Sep 30, 2014 at 10:05:00AM +0100, Nicholas Marriott wrote: If we do this then these usage functions also need to be marked __dead. Agreed, Fritjof, can you aadd that to your diff? -Otto On Sat, Sep 27, 2014 at 07:10:01PM +0200, Fritjof Bornebusch wrote: Hi, after

Re: [Patch]openrcs: atoi to strtonum

2014-09-27 Thread Otto Moerbeek
On Fri, Sep 26, 2014 at 09:23:08PM +0200, Fritjof Bornebusch wrote: On Wed, Sep 24, 2014 at 10:31:17PM +0200, Otto Moerbeek wrote: Hi, On Wed, Sep 24, 2014 at 05:13:47PM +0200, Fritjof Bornebusch wrote: Hi, I changed atoi to strtonum in order to avoid overflows. One

Re: [Patch] avoid typecast

2014-09-27 Thread Otto Moerbeek
On Sat, Sep 27, 2014 at 03:48:54PM +0200, Fritjof Bornebusch wrote: Hi, there is no need for the typecast. Committed, thanks, -Otto fritjof Index: xmalloc.c === RCS file: /cvs/src/usr.bin/rcs/xmalloc.c,v

Re: [Patch]openrcs: atoi to strtonum

2014-09-24 Thread Otto Moerbeek
On Wed, Sep 24, 2014 at 05:13:47PM +0200, Fritjof Bornebusch wrote: Hi, I changed atoi to strtonum in order to avoid overflows. One concern: atoi() does not mind trailing stuff, while strtonum() does. Did you verify that the strings are just numbers in all cases? -Otto fritjof

Re: swap affinity?

2014-09-20 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 me know

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 grafted from

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 safe. I

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 to be

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: 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: 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: $ { echo 0;

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. diff -ru sort.new/fsort.c sort.new2

Re: sort(1) updates

2014-07-02 Thread Otto Moerbeek
Op 2 jul. 2014 om 15:03 heeft Jared Yanovich slovic...@gmail.com 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 is initing the int member only safe

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: This indeed solves some problems, but I have

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

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

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_malloc and uses _dl_calloc

<    1   2   3   4   5   6   7   8   9   >