add print structure and locations options, fix locations for non
standard messages