[kaffe] CVS kaffe (robilad): fixed four jthreads warnings

Kaffe CVS cvs-commits at kaffe.org
Sat Apr 22 12:10:48 PDT 2006


PatchSet 7261 
Date: 2006/04/22 18:40:39
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
fixed four jthreads warnings

2006-04-22  Dalibor Topic  <robilad at kaffe.org>

* kaffe/kaffevm/systems/unix-pthreads/syscalls.c (jthreadedSendto),
kaffe/kaffevm/systems/unix-jthreads/syscalls.c
(jthreadedGetHostByAddr, jthreadedBind, jthreadedSendto),
kaffe/kaffevm/systems/unix-jthreads/jthread.c (jthreadedConnect),
kaffe/kaffevm/systems/unix-jthreads/jthread.h (jthreadedConnect):
Fixed prototypes to match declarations in jsyscalls.h.

* include/jsyscall.h: Fixed paramters for _sendto to
match libc prototype.

Members: 
	ChangeLog:1.4766->1.4767 
	include/jsyscall.h:1.25->1.26 
	kaffe/kaffevm/systems/unix-jthreads/jthread.c:1.142->1.143 
	kaffe/kaffevm/systems/unix-jthreads/jthread.h:1.70->1.71 
	kaffe/kaffevm/systems/unix-jthreads/syscalls.c:1.18->1.19 
	kaffe/kaffevm/systems/unix-pthreads/syscalls.c:1.36->1.37 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.4766 kaffe/ChangeLog:1.4767
--- kaffe/ChangeLog:1.4766	Sat Apr 22 15:22:33 2006
+++ kaffe/ChangeLog	Sat Apr 22 18:40:39 2006
@@ -1,5 +1,17 @@
 2006-04-22  Dalibor Topic  <robilad at kaffe.org>
 
+	* kaffe/kaffevm/systems/unix-pthreads/syscalls.c (jthreadedSendto),
+	kaffe/kaffevm/systems/unix-jthreads/syscalls.c 
+	(jthreadedGetHostByAddr, jthreadedBind, jthreadedSendto),
+	kaffe/kaffevm/systems/unix-jthreads/jthread.c (jthreadedConnect),
+	kaffe/kaffevm/systems/unix-jthreads/jthread.h (jthreadedConnect):
+	Fixed prototypes to match declarations in jsyscalls.h.
+
+	* include/jsyscall.h: Fixed paramters for _sendto to
+	match libc prototype.
+
+2006-04-22  Dalibor Topic  <robilad at kaffe.org>
+
 	* kaffe/kaffevm/binreloc.c (_br_find_exe_for_symbol): 
 	Mark parameter error as unused when binreloc is enabled.
 
Index: kaffe/include/jsyscall.h
diff -u kaffe/include/jsyscall.h:1.25 kaffe/include/jsyscall.h:1.26
--- kaffe/include/jsyscall.h:1.25	Fri Dec 30 18:38:52 2005
+++ kaffe/include/jsyscall.h	Sat Apr 22 18:40:42 2006
@@ -79,7 +79,7 @@
 		int timeout, ssize_t *);
 	int	(*_sockwrite)(int, const void *, size_t, ssize_t *);
 	int	(*_sendto)(int, const void *, size_t, int, const struct sockaddr *,
-		int, ssize_t *);
+		socklen_t, int *);
 	int	(*_setsockopt)(int, int, int, const void *, int);
 	int	(*_getsockopt)(int, int, int, void *, socklen_t *);
 	int	(*_getsockname)(int, struct sockaddr *, socklen_t *);
Index: kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.c
diff -u kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.c:1.142 kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.c:1.143
--- kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.c:1.142	Fri Jan  6 06:40:46 2006
+++ kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.c	Sat Apr 22 18:40:42 2006
@@ -2861,7 +2861,7 @@
  * Threaded socket connect.
  */
 int
-jthreadedConnect(int fd, struct sockaddr* addr, int len, int timeout)
+jthreadedConnect(int fd, struct sockaddr* addr, socklen_t len, int timeout)
 {
 	int r;
 	jlong deadline = 0;
Index: kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.h
diff -u kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.h:1.70 kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.h:1.71
--- kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.h:1.70	Sun Sep 25 02:46:52 2005
+++ kaffe/kaffe/kaffevm/systems/unix-jthreads/jthread.h	Sat Apr 22 18:40:42 2006
@@ -318,7 +318,7 @@
  */
 int jthreadedOpen(const char* path, int flags, int mode, int*);
 int jthreadedSocket(int af, int type, int proto, int*);
-int jthreadedConnect(int fd, struct sockaddr* addr, int len, int timeout);
+int jthreadedConnect(int fd, struct sockaddr* addr, socklen_t len, int timeout);
 int jthreadedAccept(int fd, struct sockaddr* addr, socklen_t* len, 
 	int timeout, int *);
 int jthreadedRead(int fd, void* buf, size_t len, ssize_t *);
Index: kaffe/kaffe/kaffevm/systems/unix-jthreads/syscalls.c
diff -u kaffe/kaffe/kaffevm/systems/unix-jthreads/syscalls.c:1.18 kaffe/kaffe/kaffevm/systems/unix-jthreads/syscalls.c:1.19
--- kaffe/kaffe/kaffevm/systems/unix-jthreads/syscalls.c:1.18	Fri Nov 25 21:01:53 2005
+++ kaffe/kaffe/kaffevm/systems/unix-jthreads/syscalls.c	Sat Apr 22 18:40:43 2006
@@ -76,7 +76,7 @@
 }
 
 static int
-jthreadedBind(int fd, struct sockaddr *addr, int namelen)
+jthreadedBind(int fd, struct sockaddr *addr, socklen_t namelen)
 {
 	int rc = 0;
 
@@ -214,7 +214,7 @@
 
 static int     
 jthreadedSendto(int a, const void* b, size_t c, int d, const struct sockaddr* e,
-		size_t f, ssize_t *out)
+		socklen_t f, int *out)
 {
 	int rc = 0;
 
@@ -306,13 +306,13 @@
 }
 
 static int
-jthreadedGetHostByAddr(const char *host, int l, int t, struct hostent** out)
+jthreadedGetHostByAddr(const char *host, size_t l, int t, struct hostent** out)
 {
 	int rc = 0;
 
 	jthread_spinon(0);
 	/* NB: same comment as for jthreadedGetHostByName applies here */
-	*out = gethostbyaddr(host, (unsigned)l, t);
+	*out = gethostbyaddr(host, l, t);
 	if (*out == 0) {
 		rc = h_errno;
 		if (rc == 0) {
Index: kaffe/kaffe/kaffevm/systems/unix-pthreads/syscalls.c
diff -u kaffe/kaffe/kaffevm/systems/unix-pthreads/syscalls.c:1.36 kaffe/kaffe/kaffevm/systems/unix-pthreads/syscalls.c:1.37
--- kaffe/kaffe/kaffevm/systems/unix-pthreads/syscalls.c:1.36	Tue Dec 20 02:02:58 2005
+++ kaffe/kaffe/kaffevm/systems/unix-pthreads/syscalls.c	Sat Apr 22 18:40:45 2006
@@ -320,11 +320,11 @@
 
 static int     
 jthreadedSendto(int a, const void* b, size_t c, int d, const struct sockaddr* e,
-		int f, ssize_t *out)
+		socklen_t f, int *out)
 {
 	int rc = 0;
 
-	*out = e ? sendto(a, b, c, d, e, (socklen_t)f) : send(a, b, c, d);
+	*out = e ? sendto(a, b, c, d, e, f) : send(a, b, c, d);
 	if (*out == -1) {
 		rc = errno;
 	}




More information about the kaffe mailing list