On Thu, Aug 03, 2006 at 07:16:40PM -0400, Pavel Roskin wrote:
> Hello!
>
> On Thu, 2006-08-03 at 15:02 -0700, aaaaa bbbbb wrote:
> > Compiling drivers (orinoco-0.13e-SN-6) i am getting
> > this warning:
> >
> > CC [M] /home/deb/orinoco-0.13e-SN-6/orinoco.o
> > /home/deb/orinoco-0.13e-SN-6/orinoco.c: In function
> > `orinoco_set_mac_address':
> > /home/deb/orinoco-0.13e-SN-6/orinoco.c:2653: warning:
> > unused variable `priv'
> >
> > Maybe this warning have something same with this
> > problem ?
>
> Unused variables only take extra space on stack. I can imagine they can
> serve as protection against buffer overflow attacks exploiting
> off-by-one errors. It's hard to imagine an unused variable to create a
> problem other than stack overflow, in which case we would be observing a
> kernel panic.
In fact, it won't even do that, since gcc will remove the unused
variable. The warning is just so your source doesn't remain cluttered
with them.
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
|