From: Dmitriy Vyukov Date: Sat, 1 Jun 2013 21:45:26 +0000 (+0400) Subject: runtime: minor code style improvements (followup to change 9778049) X-Git-Tag: go1.2rc2~1357 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=83d4cd758c20bdfa1acb13a14425db692bc445e2;p=gostls13.git runtime: minor code style improvements (followup to change 9778049) R=golang-dev, r CC=golang-dev https://golang.org/cl/9693044 --- diff --git a/src/pkg/runtime/malloc.goc b/src/pkg/runtime/malloc.goc index c0a9232776..1f035cb239 100644 --- a/src/pkg/runtime/malloc.goc +++ b/src/pkg/runtime/malloc.goc @@ -520,7 +520,7 @@ runtime·persistentalloc(uintptr size, uintptr align) { byte *p; - if(align) { + if(align != 0) { if(align&(align-1)) runtime·throw("persistentalloc: align is now a power of 2"); if(align > PageSize) diff --git a/src/pkg/runtime/symtab.c b/src/pkg/runtime/symtab.c index f68378cd17..126d0c5204 100644 --- a/src/pkg/runtime/symtab.c +++ b/src/pkg/runtime/symtab.c @@ -563,7 +563,7 @@ runtime·symtabinit(void) // Initialize tables. // Memory obtained from runtime·persistentalloc() is not scanned by GC, // this is fine because all pointers either point into sections of the executable - // or also obtained from persistentmalloc(). + // or also obtained from persistentalloc(). func = runtime·persistentalloc((nfunc+1)*sizeof func[0], 0); func[nfunc].entry = (uint64)etext; fname = runtime·persistentalloc(nfname*sizeof fname[0], 0);