Re: CVS commit: src/sys/arch/alpha/include
In article <20170114161510.b8f2ff...@cvs.netbsd.org>, Martin Husemann wrote: >-=-=-=-=-=- > >Module Name: src >Committed By: martin >Date: Sat Jan 14 16:15:10 UTC 2017 > >Modified Files: > src/sys/arch/alpha/include: asm.h > >Log Message: >Avoid stupid gcc redefinition warnings by #undef before redefine. No, this is the wrong fix! All asm.h files do that. Please back it out. I've fixed it differently (by not including asm.h in crtbegin.h). christos
Re: CVS commit: src/usr.bin/make
Module Name:src Committed By: sjg Date: Sat Jan 14 22:58:04 UTC 2017 Modified Files: src/usr.bin/make: make.1 var.c src/usr.bin/make/unit-tests: varmisc.exp varmisc.mk Log Message: Allow providing a utc value to :{gm,local}time Reviewed by: christos The man-page descriptions for these options are rather awkward: :gmtime[=utc] The value is a format string for strftime(3), using gmtime(3). If a utc value is not provided or is 0, the current time is used. It's not really clear that "the value" refers to the value of the variable being modified, rather than the value of the modification. Perhaps using an example here could make it more clear? (The example from the updated unit tests could be used, but with a utc value of 1 representing '1970-01-01 00:00:01 UTC'.) Or reword to something along the lines of Convert the specified utc value using the variable's value as a format string for strftime(3). If no utc value is given or is 0, the current gmtime(3) / localtime(3) is used. Also, is the value passed to :localtime[=utc] really a utc value? Or is it a "corrected" localtime(3) value? +--+--++ | Paul Goyette | PGP Key fingerprint: | E-mail addresses: | | (Retired)| FA29 0E3B 35AF E8AE 6651 | paul at whooppee.com | | Kernel Developer | 0786 F758 55DE 53BA 7731 | pgoyette at netbsd.org | +--+--++
Re: CVS commit: src/sys/kern
On Sun, Jan 15, 2017 at 01:28:14AM +, Maya Rashish wrote: > - strcpy(name, t->l_name); > + strlcpy(name, t->l_name, sizeof(name)); > This seems limited in setname, and getname was unlimited. I don't see where else it is set, let me know if I'm wrong!
Re: CVS commit: src/sys/kern
> @@ -162,7 +162,7 @@ module_load_plist_vfs(const char *modpat > base = NULL; > > proppath = PNBUF_GET(); > - strcpy(proppath, modpath); > + strlcpy(proppath, modpath, MAXPATHLEN); > pathlen = strlen(proppath); > if ((pathlen >= 6) && (strcmp(&proppath[pathlen - 5], ".kmod") == 0)) { > strcpy(&proppath[pathlen - 5], ".plist"); > The sole caller to this function is in the same file. It uses snprintf with MAXPATHLEN to set path.