Re: Fwd: Mac Address in C

Massimo Consiglio <[email protected]>
Newsgroups gmane.linux.debian.devel.italian
Message-ID <[email protected]>
Alle Monday 04 June 2007, Fabrizio Gattuso ha scritto:
> On 4 Giu, 22:10, "Andrea Ferraresi" <[email protected]>
>
> wrote:
> > scusate il repost ma ho mandato la mail a fabrizio in privato
> >
> > ---------- Forwarded message ----------
> > From: Andrea Ferraresi <[email protected]>
> > Date: 4-giu-2007 22.06
> > Subject: Re: Mac Address in C
> > To: Fabrizio Gattuso <[email protected]>
> >
> > tutte le informazioni della scheda vengono date dal comando ifconfig
> > quindi basta dare il seguente comando
> >
> > ifconfig | grep HW
> >
> > ciao.
>
> intendevo in C  :)  non da shell!

Puoi utilizzare ioctl() leggendo i dati della richiesta SIOCGIFCONF nella 
struttura ifreq.

-- 
Saluti
Massimo Consiglio

ICQ #44273373

http://www.bozzetto.com/features/West/west14.htm

gpg --keyserver search.keyserver.net --recv-key ACD2E735
http://keyserver.linux.it/pks/lookup?op=get&search=0xACD2E735
FE0C E30D 2715 8EB2 AAFE  6B2F 9595 DB40 ACD2 E735
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.