Move main to bottom.
Make check_log() static like all others.  Zap long comment at
top of file.