Date: Thu, 26 Aug 2004 18:44:34 +0200 From: Mmaist <mmaist@email.it> To: freebsd-hackers@freebsd.org Subject: Re: syscalls implementation Message-ID: <fb3abb0694aaefe6c48f40c4b6d562b1@213.140.6.102>
next in thread | raw e-mail | index | archive | help
> You could overwrite sysent[SYS_kldload] to point to your own kldload
> function. After you do what you want to, you return what the original
> kldload returns. Meaning, call the original kldload and return it\'s
value.
>
> int (*orig_kldload)(struct thread *, struct kldload_args *) =
> sysent[SYS_kldload];
> int my_kldload(struct thread *, struct kldload_args *);
>
> int my_kldload(struct thread *td, struct kldload_args *uap)
> {
> do_stuff_here();
>
> return (*orig_kldload)(td, uap);
> }
>
> lattera
You didn\'t point the problem. kldload(2) accepts just one const char* and
the only one implementation I\'ve found of kldload(2) is int kldload(struct
thread *, struct kldload_args *), so I guess there could be kldload(const
char*) implementation in another file; where is?
thanks in advance
markus
--
Email.it, the professional e-mail, gratis per te: http://www.email.it/f
Sponsor:
Incredibile offerta: 18 eccellenti vini Giordano + 7 gustose specialità
alimentari compreso un carrello dispensa o una batteria di pentole.
Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=2619&d=20040826
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?fb3abb0694aaefe6c48f40c4b6d562b1>
