more warnings
initialize headerCode variable properly
update to latest APIs