gpt4 book ai didi

go - 从源代码构建 Go 时测试失败

转载 作者:IT王子 更新时间:2023-10-29 02:06:02 26 4
gpt4 key购买 nike

当我从源代码构建 Golang 时,我无法通过构建测试:

hg clone -u release https://code.google.com/p/go
cd go/src
./all.bash

....
ok net/url 0.005s
ok os 0.595s
--- FAIL: TestExtraFiles (0.12 seconds)
exec_test.go:230: TestExtraFiles: Something already leaked - closed fd 3
exec_test.go:403: Run: exit status 1; stdout "leaked parent file. fd = 10; want 9\n", stderr ""
FAIL
FAIL os/exec 0.822s
ok os/signal 0.511s

请帮忙。这是在我的 webfaction 共享机器上。

[~] lsb_release -a
LSB Version: :core-4.0-ia32:core-4.0-noarch:graphics-4.0-ia32:graphics-4.0-noarch:printing-4.0-ia32:printing-4.0-noarch
Distributor ID: CentOS
Description: CentOS release 5.10 (Final)
Release: 5.10
Codename: Final

最佳答案

根据 issue 3001,这是 CentOS 5/RHEL 5 中的错误, 基本上内核会忽略 O_CLOEXEC

因此,要么忽略错误(坏主意),要么转移到更新的 Linux 版本。

关于go - 从源代码构建 Go 时测试失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24197542/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com