mirror of
https://github.com/ksherlock/marignotti.git
synced 2025-01-06 19:30:18 +00:00
fix compile errors.
This commit is contained in:
parent
98413db36b
commit
7c7a339b39
2
driver.c
2
driver.c
@ -116,7 +116,7 @@ int driver(
|
|||||||
|
|
||||||
case PRU_BIND:
|
case PRU_BIND:
|
||||||
// KERNbind(int fd, struct sockaddr *my_addr, int addrlen, int *ERRNO)
|
// KERNbind(int fd, struct sockaddr *my_addr, int addrlen, int *ERRNO)
|
||||||
return mbind(socknum, p1, p2, p3, p4, p5);
|
return mbind(e, p1, p2, p3, p4, p5);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case PRU_CONNECT:
|
case PRU_CONNECT:
|
||||||
|
@ -50,10 +50,10 @@ static int sock_accept(
|
|||||||
DecBusy();
|
DecBusy();
|
||||||
|
|
||||||
tmp.sin_family = AF_INET;
|
tmp.sin_family = AF_INET;
|
||||||
tmp.sin_port = port;
|
tmp.sin_port = dr.drDestPort;
|
||||||
tmp.sin_addr = dr.drDestIP;
|
tmp.sin_addr = dr.drDestIP;
|
||||||
|
|
||||||
copy_address(&tmp, addr, addrlen);
|
copy_addr(&tmp, addr, addrlen);
|
||||||
}
|
}
|
||||||
|
|
||||||
*newfd = ipid;
|
*newfd = ipid;
|
||||||
|
@ -2,7 +2,8 @@ CFLAGS += $(DEFINES) -v -w
|
|||||||
OBJS = main.o table.o driver.o s16debug.o \
|
OBJS = main.o table.o driver.o s16debug.o \
|
||||||
mattach.o mconnect.o mread.o mwrite.o mdetach.o \
|
mattach.o mconnect.o mread.o mwrite.o mdetach.o \
|
||||||
mioctl.o mshutdown.o mgetsockopt.o msetsockopt.o \
|
mioctl.o mshutdown.o mgetsockopt.o msetsockopt.o \
|
||||||
mgetsockname.o mselect.o maccept.o mlisten.o
|
mgetsockname.o mgetpeername.o mselect.o maccept.o \
|
||||||
|
mbind.o mlisten.o
|
||||||
|
|
||||||
TARGET = marignotti
|
TARGET = marignotti
|
||||||
|
|
||||||
@ -27,6 +28,8 @@ mshutdown.o: mshutdown.c marignotti.h
|
|||||||
mioctl.o: mioctl.c marignotti.h
|
mioctl.o: mioctl.c marignotti.h
|
||||||
mgetsockname.o: mgetsockname.c marignotti.h
|
mgetsockname.o: mgetsockname.c marignotti.h
|
||||||
mselect.o: mselect.c marignotti.h
|
mselect.o: mselect.c marignotti.h
|
||||||
|
mgetpeername.o: mgetpeername.c marignotti.h
|
||||||
|
mbind.o: mbind.c marignotti.h
|
||||||
mlisten.o: mlisten.c marignotti.h
|
mlisten.o: mlisten.c marignotti.h
|
||||||
maccept.o: maccept.c marignotti.h
|
maccept.o: maccept.c marignotti.h
|
||||||
|
|
||||||
|
@ -24,8 +24,8 @@ int mgetpeername(Entry *e, void *p1, void *p2, void *p3, void *p4, void *p5)
|
|||||||
s16_debug_printf("getpeername");
|
s16_debug_printf("getpeername");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!addrlen) return EINVAL;
|
if (!addrlen || !addr) return EINVAL;
|
||||||
if (!sock_addr) return EINVAL;
|
if (!*addrlen) return 0;
|
||||||
|
|
||||||
IncBusy();
|
IncBusy();
|
||||||
TCPIPGetDestination(e->ipid, &dr);
|
TCPIPGetDestination(e->ipid, &dr);
|
||||||
|
@ -26,8 +26,8 @@ int mgetsockname(Entry *e, void *p1, void *p2, void *p3, void *p4, void *p5)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (!addrlen) return EINVAL;
|
if (!addrlen || !addr) return EINVAL;
|
||||||
if (!sock_addr) return EINVAL;
|
if (!*addrlen) return 0;
|
||||||
|
|
||||||
tmp.sin_family = AF_INET;
|
tmp.sin_family = AF_INET;
|
||||||
IncBusy();
|
IncBusy();
|
||||||
|
Loading…
Reference in New Issue
Block a user