fixed double start bug for daemon