On Thu, Mar 13, 2008 at 01:18:46AM +0000, Paul Brook wrote: > > That's the '&' which is wrong here. The string can be accessed with > > *((uint32_t *)devid). So you can simply use: > > > > ret = le32_to_cpu(*((uint32_t *)devid)) > > No you can't. Even ignoring the aliasing violation, devid might not be > sufficiently aligned. >
Oops you are right, I have been troubled by the original code. As suggested by Paul on IRC, the best is most probably to hardcode the hex values and put the string on a comment. -- .''`. Aurelien Jarno | GPG: 1024D/F1BCDB73 : :' : Debian developer | Electrical Engineer `. `' [EMAIL PROTECTED] | [EMAIL PROTECTED] `- people.debian.org/~aurel32 | www.aurel32.net