Fix daemon mode in multiple programs under OSX

  - ccnet-server
  - ccnet