nmsg_output: removed dangling pointer in callback

resolves issue #5