debugger: guard against call from non-node context
Fix a segmentation fault when the debug message handler was called from
a context without an associated node::Environment
.
Fixes: https://github.com/nodejs/node/issues/4261 Fixes: https://github.com/nodejs/node/issues/4322
R=@indutny?