Source file src/runtime/runtime_boring.go

     1  // Copyright 2017 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  package runtime
     6  
     7  import _ "unsafe" // for go:linkname
     8  
     9  //go:linkname boring_runtime_arg0 crypto/internal/boring.runtime_arg0
    10  func boring_runtime_arg0() string {
    11  	// On Windows, argslice is not set, and it's too much work to find argv0.
    12  	if len(argslice) == 0 {
    13  		return ""
    14  	}
    15  	return argslice[0]
    16  }
    17  
    18  //go:linkname fipstls_runtime_arg0 crypto/internal/boring/fipstls.runtime_arg0
    19  func fipstls_runtime_arg0() string { return boring_runtime_arg0() }
    20  

View as plain text