Merge 34717 from ros-amd64-bringup branch:

- Fix prototypes of _findfirst, _findnext, _findclose, _findfirsti64, _findnexti64 _wfindfirst, _wfindnext, _wfindfirst64, _wfindnext64, strndup, 
- Fix a number of pointer to int casts

svn path=/trunk/; revision=35695
This commit is contained in:
Timo Kreuzer 2008-08-27 03:59:24 +00:00
parent 9a1009363b
commit 57164f6854
8 changed files with 42 additions and 58 deletions

View file

@ -13,6 +13,7 @@
/* Needed for the atexit prototype. */
#include <stdlib.h>
#include <stddef.h>
typedef void (*func_ptr) (void);
extern func_ptr __CTOR_LIST__[];
@ -37,8 +38,8 @@ __do_global_dtors (void)
void
__do_global_ctors (void)
{
unsigned long nptrs = (unsigned long) __CTOR_LIST__[0];
unsigned i;
unsigned long nptrs = (unsigned long) (ptrdiff_t) __CTOR_LIST__[0];
unsigned long i;
/*
* If the first entry in the constructor list is -1 then the list
@ -47,8 +48,7 @@ __do_global_ctors (void)
*/
if (nptrs == -1)
{
for (nptrs = 0; __CTOR_LIST__[nptrs + 1] != 0; nptrs++)
;
for (nptrs = 0; __CTOR_LIST__[nptrs + 1] != 0; nptrs++);
}
/*
@ -77,3 +77,4 @@ __main (void)
}
}