From d1caad439334b29983c0bb3a9222f2eeb60a25a8 Mon Sep 17 00:00:00 2001 From: Olof Kindgren Date: Mon, 6 Feb 2017 23:38:38 +0900 Subject: [PATCH] or1k: Make open reentrant or1k uses reentrant calls by default, but there was no open_r defined which caused failure in C++/C code such as: int main() { std::cout << "test\n"; return 0; } or int main() {open(".", 0);} --- libgloss/or1k/syscalls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libgloss/or1k/syscalls.c b/libgloss/or1k/syscalls.c index 690d21ad1..3e2ad22af 100644 --- a/libgloss/or1k/syscalls.c +++ b/libgloss/or1k/syscalls.c @@ -124,7 +124,7 @@ _lseek_r(struct _reent *reent, int file, _off_t ptr, int dir) } int -_open(struct _reent *reent, char *file, int flags, int mode) +_open_r(struct _reent *reent, const char *file, int flags, int mode) { reent->_errno = ENOSYS; return -1;