newlib: update

git-svn-id: svn://kolibrios.org@3065 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Sergey Semyonov (Serge)
2012-11-26 10:18:42 +00:00
parent 16ef653fe4
commit a1006b9202
51 changed files with 1196 additions and 542 deletions
@@ -65,11 +65,13 @@ _DEFUN(_close_r, (ptr, fd),
fh = (__file_handle*) __getOSHandle( fd );
_free_r(ptr, fh->name);
_free_r(ptr, fh);
__freePOSIXHandle( fd );
__SetIOMode_nogrow( fd, 0 );
if( fd > STDERR_FILENO )
{
_free_r(ptr, fh->name);
_free_r(ptr, fh);
__freePOSIXHandle( fd );
__SetIOMode_nogrow( fd, 0 );
}
return 0;
}
@@ -29,6 +29,19 @@ void init_reent()
__sinit(ent);
}
void init_global_reent()
{
struct _reent *ent;
ent =_GLOBAL_REENT;
_REENT_INIT_PTR(ent);
__asm__ __volatile__(
"movl %0, %%fs:12"
::"r"(ent));
__sinit(ent);
}
void __mutex_lock(volatile int *val)