blobmsg: fix dynamic string buffer length calculation