Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 558436 - sys-apps/net-tools has unaligned accesses
Summary: sys-apps/net-tools has unaligned accesses
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL: http://sourceforge.net/p/net-tools/ma...
Whiteboard:
Keywords:
Depends on:
Blocks: unaligned-access
  Show dependency tree
 
Reported: 2015-08-22 20:38 UTC by Matt Turner
Modified: 2015-11-24 14:56 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Matt Turner gentoo-dev 2015-08-22 20:38:08 UTC
Running /bin/route on alpha is enough to generate 63 unaligned accesses. Compiling with -Wcast-align shows other problematic bits.
Comment 1 SpanKY gentoo-dev 2015-08-25 22:56:47 UTC
this largely comes down to net-tools using struct sockaddr in many places for storage and then casting it to other sockaddr types (which might have higher alignment requirements).  switching everything to sockaddr_storage should fix it, but requires a good amount of yak shaving since the pointer type is encoded in many many functions :/.

i've done it locally, and even then it doesn't fix all points, just the vast majority.  it might be the few that are left we don't care about until someone actually complains (as the alignment coming through might be sufficient).
Comment 2 SpanKY gentoo-dev 2015-08-26 03:36:10 UTC
pushed a bunch of fixes upstream, but the last two needed to fix this particular crash are pending RFC on the mailing list
Comment 3 Matt Turner gentoo-dev 2015-11-15 01:55:43 UTC
Thanks Mike.

Looks like there wasn't much discussion. Time to push the last two patches upstream?
Comment 4 SpanKY gentoo-dev 2015-11-24 14:56:23 UTC
i've pushed them upstream now and included in the new net-tools-1.60_p20151124144947

http://gitweb.gentoo.org/repo/gentoo.git/commit/?id=eb8750476cb74179f39e08123acc52130aaccb96