Re: newsyslog timestamp

2017-03-15 Thread Craig Skinner
Hiya, On Wed, 15 Mar 2017 02:19:10 +1100 bytevolcano wrote: > Is it worth making newsyslog use the syslog API instead of directly > writing to the top of the file? From syslogd(8): CAVEATS syslogd does not create files, it only logs to existing ones. Cheers, -- Craig Skinner |

Re: man.cgi(8): add unique HTML titles

2017-03-15 Thread Ingo Schwarze
Hi, Anton Lindqvist wrote on Sun, Feb 05, 2017 at 10:30:32AM +0100: > Here's a proposal to add unique HTML titles to man-pages served > using man.cgi. The name of the man-page is used as a title prefix That made sense to me, so i committed the version below and installed it on man.openbsd.org.

Re: newsyslog timestamp

2017-03-15 Thread Alexander Bluhm
On Mon, Mar 13, 2017 at 11:14:36PM +0100, Alexander Bluhm wrote: > I think the combination of local time and time zone without fractions > of seconds is the best choice for newsyslog. Or should we use > 2017-03-13T21:30:04.822Z in newsyslogd? Regarding all the Feedback I summarize: - we need

Re: [patch 1/2] doas(1): Moved some parsing from env.c into parse.y

2017-03-15 Thread Ted Unangst
bytevolc...@safe-mail.net wrote: > > Also, I'm not sure how you tested this, because it doesn't work like > > you say it does. setenv { HERE=there } copies both $HERE and $there > > from the current environment. It does not set HERE=there. That's very > > wrong. > > > > How are you getting that

Re: [patch 1/2] doas(1): Moved some parsing from env.c into parse.y

2017-03-15 Thread bytevolcano
On Wed, 15 Mar 2017 13:22:53 -0400 "Ted Unangst" wrote: ... > > 1. Loops - Use C99 style initialisation? > > for(int i = 0; i < monsters; i < 666) > > No. > > > 3. Anything of major concern. > > Adding a new character to the lexer potentially breaks existing >

syslogd ttymsg fd leak

2017-03-15 Thread Alexander Bluhm
Hi, I think there is a file descriotor leak in the syslogd(8) ttymsg() error path. When we return early with an error, we must close the newly opened file descriptor first. ok? bluhm Index: usr.sbin/syslogd/ttymsg.c === RCS file:

Re: [patch 1/2] doas(1): Moved some parsing from env.c into parse.y

2017-03-15 Thread bytevolcano
On Wed, 15 Mar 2017 20:15:26 -0400 "Ted Unangst" wrote: > Did I get it backwards? If you have setenv { HERE= there }, your diff > changes behavior. > Now I see where you are coming from. It's meant to empty $HERE, and copy $there. Thanks, I'll look into this.

Re: Making it easier to install clang alongside gcc

2017-03-15 Thread Jonathan Gray
On Wed, Mar 15, 2017 at 09:53:41PM +0100, Mark Kettenis wrote: > It's currently a bit of a pain to install clang and ld.lld, but keep > gcc and ld.bfd as the default compiler/linker. You can't rebuild > clang with base gcc and you really want to rebuild it with clang > instead of the ports gcc

Re: SVM instructions

2017-03-15 Thread Mark Kettenis
> Date: Wed, 15 Mar 2017 16:23:33 -0700 > From: Mike Larkin > > On Wed, Mar 15, 2017 at 09:05:56PM +0100, Mark Kettenis wrote: > > Clang only accepts SVM instructions with explicit operands, for > > example: > > > > vmload %rax > > > > Unfortunately gas doesn't accept

Re: syslogd fd_tls variable

2017-03-15 Thread Alexander Bluhm
On Mon, Jan 09, 2017 at 10:46:42AM +0100, Alexander Bluhm wrote: > To implement multiple tls listen sockets in syslogd, I have to get > rid of the global variable fd_tls first. Looks like this diff got forgotten. Any ok? > Index: usr.sbin/syslogd/syslogd.c >

syslogd log.c

2017-03-15 Thread Alexander Bluhm
Hi, I want to replace the home grown syslogd(8) internal debug and logging functions with a more common log.c implementation. But of course I cannot use openlog(3), so I need something special. I have copied log.[ch] form ospfd(8) and adapted it to syslogd's needs. As the messages are limited

Re: SVM instructions

2017-03-15 Thread Mike Larkin
On Wed, Mar 15, 2017 at 09:05:56PM +0100, Mark Kettenis wrote: > Clang only accepts SVM instructions with explicit operands, for > example: > > vmload %rax > > Unfortunately gas doesn't accept this form. It does accept the > instruction without any operands: > > vmload > > and the

Re: [patch 1/2] doas(1): Moved some parsing from env.c into parse.y

2017-03-15 Thread Ted Unangst
bytevolc...@safe-mail.net wrote: > Instead of having to use another 1KB buffer just to figure out where > the '=' sign is, use the parser infrastructure already present. Also > allows for variable timeout option. Another (negligible) advantage: if > one day someone wants to change the maximum line

Re: whois: remove pointless realloc()

2017-03-15 Thread Todd C. Miller
On Wed, 15 Mar 2017 09:57:26 -0600, "Todd C. Miller" wrote: > There's no need to realloc() a chunk of memory when you don't care > about the old contents, we don't want have to memcpy() the old > contents to the new chunk only to throw it away. > While here, use asprintf() to simplify things.

Re: whois: remove pointless realloc()

2017-03-15 Thread Theo de Raadt
> - for (name = *argv; (name = *argv) != NULL; argv++) > - rval += whois(name, host ? host : choose_server(name, country), > - port_whois, flags); > - exit(rval); > + for (name = *argv; (name = *argv) != NULL; argv++) { > + server = host ? host :

[patch 1/2] doas(1): Moved some parsing from env.c into parse.y

2017-03-15 Thread bytevolcano
Instead of having to use another 1KB buffer just to figure out where the '=' sign is, use the parser infrastructure already present. Also allows for variable timeout option. Another (negligible) advantage: if one day someone wants to change the maximum line length, they only need to do so in one

whois: remove pointless realloc()

2017-03-15 Thread Todd C. Miller
There's no need to realloc() a chunk of memory when you don't care about the old contents, we don't want have to memcpy() the old contents to the new chunk only to throw it away. While here, use asprintf() to simplify things. - todd Index: usr.bin/whois/whois.c

Re: httpd: expand HTTP Host

2017-03-15 Thread Rivo Nurges
Hi! New simplified version of the patch. Test results: HTTP 1.1 with Host: HTTP/1.0 301 Moved Permanently Location: https://testhttp.int/ HTTP 1.0 with Host: HTTP/1.0 301 Moved Permanently Location: https://testhttp.int/ HTTP 1.1 without Host: HTTP/1.0 400 Bad Request HTTP 1.0 without Host:

SVM instructions

2017-03-15 Thread Mark Kettenis
Clang only accepts SVM instructions with explicit operands, for example: vmload %rax Unfortunately gas doesn't accept this form. It does accept the instruction without any operands: vmload and the incorrect form: vmload (%rax) The diff below fixes this. Slight flaw with this diff is

Re: httpd: expand HTTP Host

2017-03-15 Thread Florian Obser
This is OK florian@ or I can commit it if someone else OKs it. On Wed, Mar 15, 2017 at 05:55:35PM +, Rivo Nurges wrote: > Hi! > > New simplified version of the patch. > > Test results: > HTTP 1.1 with Host: > HTTP/1.0 301 Moved Permanently > Location: https://testhttp.int/ > > HTTP 1.0

Re: [PATCH] sensorsd - Command line switch for alternative configuration file

2017-03-15 Thread Silamael
On 14.03.2017 12:55, Alexander Bluhm wrote: > All other error messages are lower case. I would write "err(1, > "access configuration file %s", configfile)" as err(3) privides a > reason anyway. > > apart from that OK bluhm@ > Upated diff. -- Matthias Index: sensorsd.8

Making it easier to install clang alongside gcc

2017-03-15 Thread Mark Kettenis
It's currently a bit of a pain to install clang and ld.lld, but keep gcc and ld.bfd as the default compiler/linker. You can't rebuild clang with base gcc and you really want to rebuild it with clang instead of the ports gcc after boostrapping. And overwriting the default compiler/linker links is

Re: httpd: expand HTTP Host

2017-03-15 Thread Reyk Floeter
OK reyk - go for it Florian Obser : > > This is OK florian@ or I can commit it if someone else OKs it. > >> On Wed, Mar 15, 2017 at 05:55:35PM +, Rivo Nurges wrote: >> Hi! >> >> New simplified version of the patch. >> >> Test results: >> HTTP 1.1 with Host: >>