jtendo/binpp — pull request #4 by benbro (2012-09-09 05:14:41+00:00)
Title: Output the whole binary at once in pprint and allow just formatting the binary

When using binpp:pprint/1 from several processes at the same time, the output of pprint/1 of several binaries might be mixed because each line of the binary is printed separately.
The first commit prints the whole binary at once when using pprint/1.

It's useful to be able to use the output of pprint/1 with error_logger or something else instead of printing it to the shell so I added pbin/1 to return an iolist. You can print it with error_logger:info_msg("~p~n", [binpp:pbin(<<"mybin">>)]).

pprint/1 can use pbin/1 but I didn't change that for simplicity.
You'll might want to change the name of the pbin function.

Thanks