Warning fixes
These commits seem to be the minimum that's required to get a warning-free build on Fedora 29. The section name fix could do with some tests, but I was not sure whether there was an existing test where those would go, or to create a new one. The existing tests pass locally, at least.