Added check for data directory before starting the daemon. (fixes #1)