Skip to content

Commit

Permalink
Fix compilation errors in the test samples
Browse files Browse the repository at this point in the history
Signed-off-by: Cosmin Cojocar <ccojocar@cloudbees.com>
  • Loading branch information
Cosmin Cojocar committed Jan 4, 2021
1 parent 23ef700 commit a5911ad
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions testutils/source.go
Original file line number Diff line number Diff line change
Expand Up @@ -582,7 +582,6 @@ import (
"fmt"
"log"
"net/http"
"net/http/pprof"
)
func main() {
Expand Down Expand Up @@ -1632,8 +1631,11 @@ import (
func main() {
repoFile := "path_of_file"
relFile := filepath.Rel(repoFile)
_, err := os.OpenFile(relFile, os.O_RDONLY, 0600)
relFile, err := filepath.Rel("./", repoFile)
if err != nil {
panic(err)
}
_, err = os.OpenFile(relFile, os.O_RDONLY, 0600)
if err != nil {
panic(err)
}
Expand Down Expand Up @@ -2229,10 +2231,11 @@ func printVector() {
fmt.Println()
}
func foo() (int, *string, string) {
func foo() (int, **string, *string) {
for _, item := range vector {
return 0, &item, item
}
return 0, nil, nil
}
func main() {
Expand Down

0 comments on commit a5911ad

Please sign in to comment.