So you you think stash_group_add_string is buggy or this issue is only with the send_cmd_prefix pref?
In #3151 the commit be739e28a6e29aeb08912af36620a4fb78b31176 was identified as first buggy commit, but that doesn't change stash_group_add_string as far as I can tell.