libmpdclient icon indicating copy to clipboard operation
libmpdclient copied to clipboard

MPD_ERROR_MALFORMED on response lines longer than 4KiB

Open joshkunz opened this issue 4 years ago • 1 comments

Howdy, I develop an MPD client called ashuffle that uses libmpdclient. A user filed an issue where a long comment on a track caused an mpd_recv_song as part of an mpd_list_all_meta command to fail with the error message Response line too large, which I presume is an MPD_ERROR_MALFORMED. It looks like this is caused by libmpdclient's fixed 4KiB buffer size. The user was able to confirm that a line in the raw response from MPD was over the 4KiB limit (4.4KiB). I have not directly confirmed this at HEAD but the issue appears to be in the code.

It looks like this has come up before in issue #51, and PR #53 has a proposed fix, but there hasn't been any activity on it in almost 10mo. Would the libmpdclient maintainers be open to moving forward with that, or another, fix?

joshkunz avatar Feb 11 '21 03:02 joshkunz

A problem with the 4kB buffer limit poped up also in myMPD. A file was tagged with a comment longer than this limit.

jcorporation avatar Jul 17 '21 15:07 jcorporation