I do not see this one
"if (remaining > 0)
        send_one_dtmf(vd);"
does not have else statement.