[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: [netbsd-3] src/sys -- uipc_usrreg.c
2009/4/11 Soren Jacobsen <snj%netbsd.org@localhost>:
> Module Name: src
> Committed By: snj
> Date: Sat Apr 11 06:18:21 UTC 2009
> Modified Files:
> src/sys/kern [netbsd-3]: uipc_usrreq.c
> src/sys/sys [netbsd-3]: file.h
> Log Message:
> Apply patch (requested by mlelstv in ticket #2004):
> Avoid deep recursion and file descriptor exhaustion.
> 1. unp_detach: go not call unp_gc directly for descriptors
> that are unixdomain sockets themselves. Instead mark them
> for cleanup during garbage collection.
> 2. unp_gc: handle detach of descriptors that were marked earlier.
> 3. prohibit transfer of descriptors within SCM_RIGHTS messages if
> (num_files_in_transit > maxfiles / unp_rights_ratio)
causes compilation errors in the kernel when compiling uipc_usrreg.c
at line 1272:
(void) closef(fp, (struct lwp *)0);
../../../../kern/uipc_usrreq.c: In function `unp_gc':
../../../../kern/uipc_usrreq.c:1272: warning: passing arg 2 of
`closef' from incompatible pointer type
This in turn seems to be caused by closef being declared as
int closef(struct file *, struct proc *);
(and in the netbsd-4 branch it is: int closef(struct file *, struct
lwp *); as expected the uipc_usrreg.c patch that was pulled up to both
the -3 and -4 branches.
Main Index |
Thread Index |