It took me a long time to find this and be able to make a MWE. I hope someone has an idea what is causing it and if there is a work around. This problem shows up in this small example, only when I use the mathml switch in tex4ht. Which is really strange. I've had problems before using tex4ht with mathml, but these show up in the HTML file, never in the actual compile stage.
I was trying to use a solution to add dashed lines to a matrix as shown is it possible to add dashed lines between rows/column of pmatrix from amsmath?
\documentclass{article}
\usepackage{amsmath}
\usepackage{easybmat}
\begin{document}
\begin{multline*}
\bgroup
\renewenvironment{pmatrix}{\left(\begin{BMAT}(@){c.c}{c.c}}
{\end{BMAT}\right)}
\begin{pmatrix}
A & B\\
C & D
\end{pmatrix}
\egroup
\end{multline*}
\end{document}
compiles with no problem with pdflatex

But gives this error with tex4ht
htlatex foo.tex "htm,mathml"
(/usr/local/texlive/2013/texmf-dist/tex/generic/tex4ht/html-mml.4ht)
(/usr/local/texlive/2013/texmf-dist/tex/generic/tex4ht/html4-uni.4ht))
(./foo.aux)
l.16 --- TeX4ht warning --- \halign translated into linear text ---
! Missing # inserted in alignment preamble.
<to be read again>
&
l.16 \end{multline*}
?
but using this command, it now compiles fine and the HTML file displays fine with the dashed lines in the matrix.
htlatex foo.tex "htm" %ok
If I remove the multline* environment, it now works ok in both modes
\documentclass{article}
\usepackage{amsmath}
\usepackage{easybmat}
\begin{document}
\[
\bgroup
\renewenvironment{pmatrix}{\left(\begin{BMAT}(@){c.c}{c.c}}
{\end{BMAT}\right)}
\begin{pmatrix}
A & B\\
C & D
\end{pmatrix}
\egroup
\]
\end{document}
htlatex foo.tex "htm" %ok
htlatex foo.tex "htm,mathml" %ok compile, but wrong HTML display on firefox

The above code was small fragment from large file.
Any idea what is causing this error and is there a workaround it? I'd like to use mathml since I use mathjax for final display (in this small example, I did not show this) and like to keep using mathml. I also need to use \usepackage{easybmat}.
One final fact point: If I remove the easybmat part, then it works OK again:
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{multline*}
\begin{pmatrix}
A & B\\
C & D
\end{pmatrix}
\end{multline*}
\end{document}
htlatex foo.tex "htm,mathml" %ok
htlatex foo.tex "htm" %ok
But I need to use easybmat to add the dashed lines as explained in the question here
So the problem shows up, only when using easybmat with multline. Fyi, here is a question also on error using multline with pmatrix, not sure if it is related Error with pmatrix inside multline* inside minipage inside tabular
texlive 2013, on linux mint 16
tex4ht.c (2012-07-25-19:36 kpathsea)

I am using tex4ht 2014. screen shot of the folder
screen shot of HTML
pmatrix, in the case of pdf generation, use version withBMAT, and for html, use normal pmatrix, you can add lines withcss– michal.h21 Mar 05 '14 at 09:42