modifications for mac and bsd date
Added untested OSX compatibility.
Changed START_WITH_BREAK to DO_BREAK.
Check for non-zero value. Fixes #2.