On Tue, Jan 18, 2011 at 04:09:14PM +0300, Sergey Naumov wrote: > 2011/1/18 Johannes Stezenbach <[email protected]>: > > The following compiles cleanly (but not tested): > > > > /* Link detection routines and table */ > > > > +union mii_ifreq { > > + struct ifreq ifreq; > > + struct mii_ioctl_data mii; > > +}; > > + > > Denys has already thought about this solution: > > union { > > struct ifreq ifreq; > > struct { > > char padding[offsetof(struct ifreq, ifr_data)]; > > struct mii_ioctl_data mii; > > } s; > >} u; > > If struct mii_ioctl_data (or union ifr_ifru) was the first element of > struct ifreq you could use this solution, but it wasn't.
Apparently you didn't read the full patch. Johannes _______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
