runtime: remove unused getenv function

Change-Id: I49cda99f81b754e25fad1483de373f7d07d64808
Reviewed-on: https://go-review.googlesource.com/6452
Reviewed-by: Keith Randall <khr@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
David Crawshaw 2015-03-02 04:14:49 -05:00
parent 8012a2e9c9
commit dac3f486ac
2 changed files with 0 additions and 18 deletions

View File

@ -6,15 +6,6 @@ package runtime
import "unsafe"
func getenv(s *byte) *byte {
val := gogetenv(gostringnocopy(s))
if val == "" {
return nil
}
// Strings found in environment are NUL-terminated.
return &bytes(val)[0]
}
var tracebackbuf [128]byte
func gogetenv(key string) string {

View File

@ -8,15 +8,6 @@ package runtime
import "unsafe"
func getenv(s *byte) *byte {
val := gogetenv(gostringnocopy(s))
if val == "" {
return nil
}
// Strings found in environment are NUL-terminated.
return &bytes(val)[0]
}
func gogetenv(key string) string {
env := environ()
if env == nil {