ANSI C only version of previous pull request

Paring down to remove all C99 features, but under protest ;)

Please see my comment at https://github.com/lvandeve/lodepng/pull/2#issuecomment-64910517 for explanation.