Page MenuHomeFreeBSD

vdevice.h: avoid gcc variably-modified warning
ClosedPublic

Authored by rlibby on Jun 29 2017, 9:39 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, May 10, 2:37 PM
Unknown Object (File)
Thu, May 7, 6:05 AM
Unknown Object (File)
Sat, May 2, 10:10 PM
Unknown Object (File)
Apr 13 2026, 3:41 PM
Unknown Object (File)
Apr 10 2026, 6:25 AM
Unknown Object (File)
Apr 10 2026, 12:11 AM
Unknown Object (File)
Apr 9 2026, 7:36 PM
Unknown Object (File)
Apr 7 2026, 9:23 PM

Details

Summary

gcc produces a "variably modified X at file scope" warning for structures that use these size definitions. I think the definitions are actually fine but can be rephrased with offsetof more cleanly anyway.

Looks like this was originally reported here: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=211540

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision is now accepted and ready to land.Jul 5 2017, 5:12 PM
This revision was automatically updated to reflect the committed changes.