Skip to content

Commit

Permalink
* signal.c, stdio.c: Remove "function declaration isn't a prototype"…
Browse files Browse the repository at this point in the history
… warnings. * unistd.c: Check for presence of gethostname and sethostname.

svn path=/trunk/mono/; revision=38279
  • Loading branch information
Jonathan Pryor committed Jan 3, 2005
1 parent f350df0 commit 6ad9da7
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 4 deletions.
5 changes: 5 additions & 0 deletions support/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
2005-01-03 Jonathan Pryor <[email protected]>

* signal.c, stdio.c: Remove "function declaration isn't a prototype" warnings.
* unistd.c: Check for presence of gethostname and sethostname.

2005-01-03 Jonathan Pryor <[email protected]>

* mph.h, x-struct-str.c: Add "const" to parameters to remove
Expand Down
6 changes: 3 additions & 3 deletions support/signal.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@ G_BEGIN_DECLS
typedef void (*mph_sighandler_t)(int);

mph_sighandler_t
Mono_Posix_Stdlib_SIG_DFL ()
Mono_Posix_Stdlib_SIG_DFL (void)
{
return SIG_DFL;
}

mph_sighandler_t
Mono_Posix_Stdlib_SIG_ERR ()
Mono_Posix_Stdlib_SIG_ERR (void)
{
return SIG_ERR;
}

mph_sighandler_t
Mono_Posix_Stdlib_SIG_IGN ()
Mono_Posix_Stdlib_SIG_IGN (void)
{
return SIG_IGN;
}
Expand Down
3 changes: 2 additions & 1 deletion support/stdio.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
*/

#include <stdio.h>
#include <stdlib.h>

#include "mph.h"

Expand Down Expand Up @@ -137,7 +138,7 @@ Mono_Posix_Stdlib_ftell (FILE* stream)
}

fpos_t*
Mono_Posix_Stdlib_CreateFilePosition ()
Mono_Posix_Stdlib_CreateFilePosition (void)
{
fpos_t* pos = malloc (sizeof(fpos_t));
return pos;
Expand Down
4 changes: 4 additions & 0 deletions support/unistd.c
Original file line number Diff line number Diff line change
Expand Up @@ -187,19 +187,23 @@ Mono_Posix_Syscall_sethostid (gint64 hostid)
}
#endif /* def HAVE_SETHOSTID */

#ifdef HAVE_GETDOMAINNAME
gint32
Mono_Posix_Syscall_getdomainname (char *name, mph_size_t len)
{
mph_return_if_size_t_overflow (len);
return getdomainname (name, (size_t) len);
}
#endif /* def HAVE_GETDOMAINNAME */

#ifdef HAVE_SETDOMAINNAME
gint32
Mono_Posix_Syscall_setdomainname (const char *name, mph_size_t len)
{
mph_return_if_size_t_overflow (len);
return setdomainname (name, (size_t) len);
}
#endif /* def HAVE_SETDOMAINNAME */

gint32
Mono_Posix_Syscall_truncate (const char *path, mph_off_t length)
Expand Down

0 comments on commit 6ad9da7

Please sign in to comment.