Hello -

I'm having an issue downloading dives from my Mares Quad Air in Subsurface, so I tried to see what I could find out more directly with libdivecomputer. The only issue I've found with libdivecomputer is the inability to parse a dump file for the Quad Air. I don't think this is related to my Subsurface issue, but figured I'd flag it anyway.

I have downloaded and built livdivecomputer on OS X (10.13.4).

I generated the attached dump file with:

./dctool -f iconhd -m 35 dump -o mares_quad_air.dump /dev/tty.SLAB_USBtoUART > dctool.log 2>&1

Parsing of the dump file fails:

./dctool -f iconhd -m 35 parse -o mares_quad_air_parsed.xml mares_quad_air.dump
Creating the parser.
Registering the data.
Parsing the dive data.
Parsing the datetime.
ERROR: Buffer overflow detected! [in mares_iconhd_parser.c:149 (mares_iconhd_parser_cache)]
ERROR: Error parsing the datetime. [in output_xml.c:229 (dctool_xml_output_write)]
ERROR: Error parsing the dive data. [in dctool_parse.c:73 (parse)]
ERROR: Data format error

However, direct download of dives works (dive download attached):

$ ./dctool -f iconhd -m 35 download -o mares_quad_air_dives.xml /dev/tty.SLAB_USBtoUART

I see that dctool_parse calls dc_parser_new2 while dctool_download calls dc_parser_new.

Am I wrong in thinking that dctool should be able to parse the dump file and produce the same results as a direct download?

Regards,
Rick