bug fix with setImmediate in node v0.8