fix errors found in xc6
Merge branch 'xc6' into develop