mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-03-20 11:00:57 +08:00
libgo/runtime: fix unused-result warning
Result of runtime_write is ignored, causing an unused-result result warning (error in my case, with -Werror=unused-result). From-SVN: r210987
This commit is contained in:
parent
b8aac16d88
commit
25e4b0497b
@ -1117,7 +1117,8 @@ runtime_needm(void)
|
||||
if(runtime_needextram) {
|
||||
// Can happen if C/C++ code calls Go from a global ctor.
|
||||
// Can not throw, because scheduler is not initialized yet.
|
||||
runtime_write(2, "fatal error: cgo callback before cgo call\n",
|
||||
int rv __attribute__((unused));
|
||||
rv = runtime_write(2, "fatal error: cgo callback before cgo call\n",
|
||||
sizeof("fatal error: cgo callback before cgo call\n")-1);
|
||||
runtime_exit(1);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user