I have the following issue. I have a file which used for storing array of some records (unknown structure). All that I know that all records separated with "." (dot). One of the "fields" of this record is a binary value.
So the structure is:
multiline_text <<binary_value>> multiline_text .
I can read file chunk-by-chunk (because it pretty large) and parse data to get actual data "<>" but it's not a binary value it's a string. I'm trying to convert it binary (to convert to term late) but i have no success.
I tried to use BIF list_to_binary (but it won't work because it is not a list) - it's already a binary. I tried to convert it to list of integers, fold them and convert and it's still is not working.
I suppose I'm missing something basic (I'm newbie in Erlang). Are there any advices?