diff options
author | Olof Kindgren <olof.kindgren@gmail.com> | 2017-02-06 23:38:38 +0900 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2017-02-13 09:16:51 +0100 |
commit | d1caad439334b29983c0bb3a9222f2eeb60a25a8 (patch) | |
tree | 3eb574196b3bc2ca8d19387758cc5297574e4fa3 /libgloss/or1k | |
parent | debaf9557e7bf4e406985e659f73b11fa405e283 (diff) | |
download | newlib-d1caad439334b29983c0bb3a9222f2eeb60a25a8.zip newlib-d1caad439334b29983c0bb3a9222f2eeb60a25a8.tar.gz newlib-d1caad439334b29983c0bb3a9222f2eeb60a25a8.tar.bz2 |
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);}
Diffstat (limited to 'libgloss/or1k')
-rw-r--r-- | libgloss/or1k/syscalls.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libgloss/or1k/syscalls.c b/libgloss/or1k/syscalls.c index 690d21a..3e2ad22 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; |