li_mcmc: corrected a few bugs that had no actual effects