some warning cleaning and c99 updates